@codedrifters/configulator 0.0.291 → 0.0.293
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 +196 -16
- package/lib/index.d.ts +197 -17
- package/lib/index.js +740 -497
- package/lib/index.js.map +1 -1
- package/lib/index.mjs +732 -497
- package/lib/index.mjs.map +1 -1
- package/package.json +1 -1
package/lib/index.mjs
CHANGED
|
@@ -3648,8 +3648,21 @@ function buildBaseBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
3648
3648
|
"| `status:in-progress` | A worker has claimed the issue and a branch exists. Set when the worker starts; cleared only when the worker opens a PR or the issue fails. |",
|
|
3649
3649
|
"| `status:ready-for-review` | A PR has been opened for this issue and is awaiting review and merge. Replaces `status:in-progress` at the moment the PR opens. |",
|
|
3650
3650
|
"| `status:needs-attention` | Automated triage has flagged the issue for human review (stale, failed worker, or ambiguous state). Humans reset this label manually. |",
|
|
3651
|
+
"| `status:deferred` | Captured for provenance only; should not be auto-dispatched. Used by consumers that want a low-priority backlog (e.g. people-profile follow-ups in research-heavy planning repos) to stay out of the orchestrator's queue until a human or a consumer-configured scheduled task promotes it. |",
|
|
3651
3652
|
"| `status:done` | The change has shipped. Set when the PR merges and the issue closes. |",
|
|
3652
3653
|
"",
|
|
3654
|
+
"### Configurable filing-site defaults",
|
|
3655
|
+
"",
|
|
3656
|
+
"The bundle-shipped `gh issue create` recipes default to",
|
|
3657
|
+
"`status:ready` + `priority:medium`. Consumers can override the",
|
|
3658
|
+
"defaults per-phase-label via",
|
|
3659
|
+
"`AgentConfigOptions.issueDefaults` \u2014 e.g. flip every",
|
|
3660
|
+
"`people:research` filing to `status:deferred` + `priority:low`",
|
|
3661
|
+
"without touching the bundle source. See the **`issueDefaults`**",
|
|
3662
|
+
"section in the configulator agent-config docs for the full",
|
|
3663
|
+
"schema and consumer example. `status:deferred` is a valid",
|
|
3664
|
+
"override value reserved for this exact use case.",
|
|
3665
|
+
"",
|
|
3653
3666
|
"### Blocking Rules",
|
|
3654
3667
|
"",
|
|
3655
3668
|
"Two rules force `status:blocked` \u2014 both are non-negotiable:",
|
|
@@ -3977,8 +3990,92 @@ function buildBaseBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
3977
3990
|
}
|
|
3978
3991
|
var baseBundle = buildBaseBundle();
|
|
3979
3992
|
|
|
3993
|
+
// src/agent/bundles/issue-defaults.ts
|
|
3994
|
+
var VALID_STATUS_VALUES = [
|
|
3995
|
+
"ready",
|
|
3996
|
+
"blocked",
|
|
3997
|
+
"in-progress",
|
|
3998
|
+
"ready-for-review",
|
|
3999
|
+
"needs-attention",
|
|
4000
|
+
"done",
|
|
4001
|
+
"deferred"
|
|
4002
|
+
];
|
|
4003
|
+
var VALID_PRIORITY_VALUES = [
|
|
4004
|
+
"critical",
|
|
4005
|
+
"high",
|
|
4006
|
+
"medium",
|
|
4007
|
+
"low",
|
|
4008
|
+
"trivial"
|
|
4009
|
+
];
|
|
4010
|
+
var DEFAULT_ISSUE_STATUS = "ready";
|
|
4011
|
+
var DEFAULT_ISSUE_PRIORITY = "medium";
|
|
4012
|
+
var DEFAULT_RESOLVED_ISSUE_DEFAULTS = {
|
|
4013
|
+
defaults: {
|
|
4014
|
+
status: DEFAULT_ISSUE_STATUS,
|
|
4015
|
+
priority: DEFAULT_ISSUE_PRIORITY
|
|
4016
|
+
},
|
|
4017
|
+
overrides: {}
|
|
4018
|
+
};
|
|
4019
|
+
function resolveIssueDefaults(config) {
|
|
4020
|
+
if (config === void 0) {
|
|
4021
|
+
return DEFAULT_RESOLVED_ISSUE_DEFAULTS;
|
|
4022
|
+
}
|
|
4023
|
+
const overrides = {};
|
|
4024
|
+
for (const [phaseLabel, override] of Object.entries(config)) {
|
|
4025
|
+
assertValidPhaseLabel(phaseLabel);
|
|
4026
|
+
assertValidOverride(phaseLabel, override);
|
|
4027
|
+
overrides[phaseLabel] = {
|
|
4028
|
+
status: override.status ?? DEFAULT_ISSUE_STATUS,
|
|
4029
|
+
priority: override.priority ?? DEFAULT_ISSUE_PRIORITY
|
|
4030
|
+
};
|
|
4031
|
+
}
|
|
4032
|
+
return {
|
|
4033
|
+
defaults: {
|
|
4034
|
+
status: DEFAULT_ISSUE_STATUS,
|
|
4035
|
+
priority: DEFAULT_ISSUE_PRIORITY
|
|
4036
|
+
},
|
|
4037
|
+
overrides
|
|
4038
|
+
};
|
|
4039
|
+
}
|
|
4040
|
+
function validateIssueDefaultsConfig(config) {
|
|
4041
|
+
return resolveIssueDefaults(config);
|
|
4042
|
+
}
|
|
4043
|
+
function labelsForPhase(resolved, phaseLabel) {
|
|
4044
|
+
return resolved.overrides[phaseLabel] ?? resolved.defaults;
|
|
4045
|
+
}
|
|
4046
|
+
function assertValidPhaseLabel(phaseLabel) {
|
|
4047
|
+
if (typeof phaseLabel !== "string" || phaseLabel.trim() === "") {
|
|
4048
|
+
throw new Error(
|
|
4049
|
+
"AgentConfigOptions.issueDefaults: phase-label keys must be non-empty strings (e.g. `people:research`)."
|
|
4050
|
+
);
|
|
4051
|
+
}
|
|
4052
|
+
}
|
|
4053
|
+
function assertValidOverride(phaseLabel, override) {
|
|
4054
|
+
if (override === null || typeof override !== "object" || Array.isArray(override)) {
|
|
4055
|
+
throw new Error(
|
|
4056
|
+
`AgentConfigOptions.issueDefaults["${phaseLabel}"] must be an object with optional \`status\` and \`priority\` fields.`
|
|
4057
|
+
);
|
|
4058
|
+
}
|
|
4059
|
+
const { status, priority } = override;
|
|
4060
|
+
if (status === void 0 && priority === void 0) {
|
|
4061
|
+
throw new Error(
|
|
4062
|
+
`AgentConfigOptions.issueDefaults["${phaseLabel}"] must declare at least one of \`status\` or \`priority\`. Empty entries are rejected because they are almost always a typo on the field name.`
|
|
4063
|
+
);
|
|
4064
|
+
}
|
|
4065
|
+
if (status !== void 0 && !VALID_STATUS_VALUES.includes(status)) {
|
|
4066
|
+
throw new Error(
|
|
4067
|
+
`AgentConfigOptions.issueDefaults["${phaseLabel}"].status="${status}" is not a recognised status value. Allowed values: ${VALID_STATUS_VALUES.join(", ")}.`
|
|
4068
|
+
);
|
|
4069
|
+
}
|
|
4070
|
+
if (priority !== void 0 && !VALID_PRIORITY_VALUES.includes(priority)) {
|
|
4071
|
+
throw new Error(
|
|
4072
|
+
`AgentConfigOptions.issueDefaults["${phaseLabel}"].priority="${priority}" is not a recognised priority value. Allowed values: ${VALID_PRIORITY_VALUES.join(", ")}.`
|
|
4073
|
+
);
|
|
4074
|
+
}
|
|
4075
|
+
}
|
|
4076
|
+
|
|
3980
4077
|
// src/agent/bundles/bcm-writer.ts
|
|
3981
|
-
function buildBcmWriterSubAgent(paths) {
|
|
4078
|
+
function buildBcmWriterSubAgent(paths, issueDefaults) {
|
|
3982
4079
|
return {
|
|
3983
4080
|
name: "bcm-writer",
|
|
3984
4081
|
description: "Writes BCM (Business Capability Model) capability-model documents through a 4-phase pipeline (outline \u2192 scaffold \u2192 context \u2192 connect), one phase per session, tracked by bcm:* GitHub issue labels with filesystem-based durability between phases. Produces BIZBOK-aligned capability documents \u2014 not requirement documents.",
|
|
@@ -4476,20 +4573,37 @@ function buildBcmWriterSubAgent(paths) {
|
|
|
4476
4573
|
" section of sibling/parent docs.",
|
|
4477
4574
|
"",
|
|
4478
4575
|
"5. **Create downstream research issues.** For each distinct item",
|
|
4479
|
-
" surfaced during authoring
|
|
4576
|
+
" surfaced during authoring, file one issue against the appropriate",
|
|
4577
|
+
" downstream bundle. Every handoff issue includes a brief scope",
|
|
4578
|
+
" statement, a link back to this BCM document for traceability, and",
|
|
4579
|
+
" a reference to the context-phase output that revealed the item.",
|
|
4580
|
+
"",
|
|
4581
|
+
" **Unfamiliar person (role holder, stakeholder).** Hand off to the",
|
|
4582
|
+
" `people-profile` bundle by creating a `people:research` issue.",
|
|
4583
|
+
" The issue must carry:",
|
|
4584
|
+
"",
|
|
4585
|
+
" - `type:people-profile`",
|
|
4586
|
+
" - `people:research`",
|
|
4587
|
+
` - \`priority:${labelsForPhase(issueDefaults, "people:research").priority}\``,
|
|
4588
|
+
` - \`status:${labelsForPhase(issueDefaults, "people:research").status}\``,
|
|
4480
4589
|
"",
|
|
4481
|
-
"
|
|
4482
|
-
"
|
|
4483
|
-
"
|
|
4484
|
-
" | Unfamiliar company (enabling vendor, partner, competitor) | `company:research` | `company-profile` |",
|
|
4485
|
-
" | Missing research topic (value stream, market sizing, etc.) | `research:scope` | `research-pipeline` |",
|
|
4590
|
+
" **Unfamiliar company (enabling vendor, partner, competitor).**",
|
|
4591
|
+
" Hand off to the `company-profile` bundle by creating a",
|
|
4592
|
+
" `company:research` issue. The issue must carry:",
|
|
4486
4593
|
"",
|
|
4487
|
-
"
|
|
4488
|
-
" -
|
|
4489
|
-
|
|
4490
|
-
|
|
4491
|
-
"
|
|
4492
|
-
"
|
|
4594
|
+
" - `type:company-profile`",
|
|
4595
|
+
" - `company:research`",
|
|
4596
|
+
` - \`priority:${labelsForPhase(issueDefaults, "company:research").priority}\``,
|
|
4597
|
+
` - \`status:${labelsForPhase(issueDefaults, "company:research").status}\``,
|
|
4598
|
+
"",
|
|
4599
|
+
" **Missing research topic (value stream, market sizing, etc.).**",
|
|
4600
|
+
" Hand off to the `research-pipeline` bundle by creating a",
|
|
4601
|
+
" `research:scope` issue. The issue must carry:",
|
|
4602
|
+
"",
|
|
4603
|
+
" - `type:research`",
|
|
4604
|
+
" - `research:scope`",
|
|
4605
|
+
` - \`priority:${labelsForPhase(issueDefaults, "research:scope").priority}\``,
|
|
4606
|
+
` - \`status:${labelsForPhase(issueDefaults, "research:scope").status}\``,
|
|
4493
4607
|
"",
|
|
4494
4608
|
" This phase assumes the `people-profile`, `company-profile`, and",
|
|
4495
4609
|
" `research-pipeline` bundles are enabled in the consuming project.",
|
|
@@ -4565,7 +4679,7 @@ function buildBcmWriterSubAgent(paths) {
|
|
|
4565
4679
|
].join("\n")
|
|
4566
4680
|
};
|
|
4567
4681
|
}
|
|
4568
|
-
function buildWriteBcmSkill(paths) {
|
|
4682
|
+
function buildWriteBcmSkill(paths, issueDefaults) {
|
|
4569
4683
|
return {
|
|
4570
4684
|
name: "write-bcm",
|
|
4571
4685
|
description: "Kick off a BCM capability-model document authoring cycle. Creates a bcm:outline issue carrying the capability name and dispatches Phase 1 (Outline) in the bcm-writer agent.",
|
|
@@ -4610,9 +4724,11 @@ function buildWriteBcmSkill(paths) {
|
|
|
4610
4724
|
"## Steps",
|
|
4611
4725
|
"",
|
|
4612
4726
|
"1. Create a `bcm:outline` issue with `type:bcm-document`,",
|
|
4613
|
-
|
|
4727
|
+
` \`priority:${labelsForPhase(issueDefaults, "bcm:outline").priority}\`, and \`status:${labelsForPhase(issueDefaults, "bcm:outline").status}\`. Body must include the`,
|
|
4614
4728
|
" verbatim capability name and any overrides.",
|
|
4729
|
+
"",
|
|
4615
4730
|
"2. Execute Phase 1 (Outline) of the bcm-writer agent.",
|
|
4731
|
+
"",
|
|
4616
4732
|
"3. Phase 1 creates a `bcm:scaffold` issue, which Phase 2 follows with",
|
|
4617
4733
|
" `bcm:context`, then Phase 4 (`bcm:connect`). Each downstream issue",
|
|
4618
4734
|
" declares its `Depends on:` predecessor. Phase 4 creates downstream",
|
|
@@ -4631,7 +4747,7 @@ function buildWriteBcmSkill(paths) {
|
|
|
4631
4747
|
].join("\n")
|
|
4632
4748
|
};
|
|
4633
4749
|
}
|
|
4634
|
-
function buildBcmWriterBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
4750
|
+
function buildBcmWriterBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
4635
4751
|
return {
|
|
4636
4752
|
name: "bcm-writer",
|
|
4637
4753
|
description: "BCM (Business Capability Model) capability-model document authoring pipeline: outline, scaffold, context, connect. Enabled by default; BIZBOK-aligned; filesystem-durable between phases.",
|
|
@@ -4676,8 +4792,8 @@ function buildBcmWriterBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
4676
4792
|
tags: ["workflow"]
|
|
4677
4793
|
}
|
|
4678
4794
|
],
|
|
4679
|
-
skills: [buildWriteBcmSkill(paths)],
|
|
4680
|
-
subAgents: [buildBcmWriterSubAgent(paths)],
|
|
4795
|
+
skills: [buildWriteBcmSkill(paths, issueDefaults)],
|
|
4796
|
+
subAgents: [buildBcmWriterSubAgent(paths, issueDefaults)],
|
|
4681
4797
|
labels: [
|
|
4682
4798
|
{
|
|
4683
4799
|
name: "type:bcm-document",
|
|
@@ -5449,7 +5565,7 @@ function buildBusinessModelsAnalystSubAgent(paths) {
|
|
|
5449
5565
|
].join("\n")
|
|
5450
5566
|
};
|
|
5451
5567
|
}
|
|
5452
|
-
function buildScanBusinessModelsSkill(paths) {
|
|
5568
|
+
function buildScanBusinessModelsSkill(paths, issueDefaults) {
|
|
5453
5569
|
return {
|
|
5454
5570
|
name: "scan-business-models",
|
|
5455
5571
|
description: "Kick off the scan phase of a business-model analysis cycle. Creates a business-models:scan issue for the supplied industry and dispatches Phase 1 of the business-models-analyst, which reads industry-discovery output and identifies segments needing a canvas.",
|
|
@@ -5488,7 +5604,7 @@ function buildScanBusinessModelsSkill(paths) {
|
|
|
5488
5604
|
"## Steps",
|
|
5489
5605
|
"",
|
|
5490
5606
|
"1. Create a `business-models:scan` issue with `type:business-model`,",
|
|
5491
|
-
|
|
5607
|
+
` \`priority:${labelsForPhase(issueDefaults, "business-models:scan").priority}\`, and \`status:${labelsForPhase(issueDefaults, "business-models:scan").status}\`. The body must include the`,
|
|
5492
5608
|
" industry slug, the source plan path (if any), and any overrides.",
|
|
5493
5609
|
"2. Execute Phase 1 (Scan) of the business-models-analyst agent.",
|
|
5494
5610
|
"3. Phase 1 creates one `business-models:canvas` issue per in-scope",
|
|
@@ -5505,7 +5621,7 @@ function buildScanBusinessModelsSkill(paths) {
|
|
|
5505
5621
|
].join("\n")
|
|
5506
5622
|
};
|
|
5507
5623
|
}
|
|
5508
|
-
function buildCanvasBusinessModelSkill(paths) {
|
|
5624
|
+
function buildCanvasBusinessModelSkill(paths, issueDefaults) {
|
|
5509
5625
|
return {
|
|
5510
5626
|
name: "canvas-business-model",
|
|
5511
5627
|
description: "Kick off the canvas phase of a business-model analysis cycle. Creates a business-models:canvas issue for the supplied industry/segment and dispatches Phase 2 of the business-models-analyst, which researches and writes the Osterwalder nine-block canvas.",
|
|
@@ -5561,7 +5677,7 @@ function buildCanvasBusinessModelSkill(paths) {
|
|
|
5561
5677
|
"## Steps",
|
|
5562
5678
|
"",
|
|
5563
5679
|
"1. Create a `business-models:canvas` issue with",
|
|
5564
|
-
|
|
5680
|
+
` \`type:business-model\`, \`priority:${labelsForPhase(issueDefaults, "business-models:canvas").priority}\`, and \`status:${labelsForPhase(issueDefaults, "business-models:canvas").status}\`.`,
|
|
5565
5681
|
" The body must include the industry slug, segment slug, and any",
|
|
5566
5682
|
" scan-report reference.",
|
|
5567
5683
|
"2. Execute Phase 2 (Canvas) of the business-models-analyst agent.",
|
|
@@ -5577,7 +5693,7 @@ function buildCanvasBusinessModelSkill(paths) {
|
|
|
5577
5693
|
].join("\n")
|
|
5578
5694
|
};
|
|
5579
5695
|
}
|
|
5580
|
-
function buildCompleteBusinessModelSkill(paths) {
|
|
5696
|
+
function buildCompleteBusinessModelSkill(paths, issueDefaults) {
|
|
5581
5697
|
return {
|
|
5582
5698
|
name: "complete-business-model",
|
|
5583
5699
|
description: "Kick off the complete phase of a business-model analysis cycle. Creates a business-models:complete issue for an already-authored canvas and dispatches Phase 3 of the business-models-analyst, which derives BIZBOK value streams, documents variations, and hands off capability work to bcm-writer.",
|
|
@@ -5621,7 +5737,7 @@ function buildCompleteBusinessModelSkill(paths) {
|
|
|
5621
5737
|
"## Steps",
|
|
5622
5738
|
"",
|
|
5623
5739
|
"1. Create a `business-models:complete` issue with",
|
|
5624
|
-
|
|
5740
|
+
` \`type:business-model\`, \`priority:${labelsForPhase(issueDefaults, "business-models:complete").priority}\`, and \`status:${labelsForPhase(issueDefaults, "business-models:complete").status}\`.`,
|
|
5625
5741
|
" Body must include the canvas document path.",
|
|
5626
5742
|
"2. Execute Phase 3 (Complete) of the business-models-analyst agent.",
|
|
5627
5743
|
"",
|
|
@@ -5636,7 +5752,7 @@ function buildCompleteBusinessModelSkill(paths) {
|
|
|
5636
5752
|
].join("\n")
|
|
5637
5753
|
};
|
|
5638
5754
|
}
|
|
5639
|
-
function buildBusinessModelsBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
5755
|
+
function buildBusinessModelsBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
5640
5756
|
return {
|
|
5641
5757
|
name: "business-models",
|
|
5642
5758
|
description: "Business-model authoring pipeline: Osterwalder Business Model Canvas plus BIZBOK value streams per industry segment. 3 phases (scan, canvas, complete) with business-models:* phase labels. Sits between industry-discovery and bcm-writer in the research pipeline. Enabled by default; domain-neutral; filesystem-durable between phases.",
|
|
@@ -5688,9 +5804,9 @@ function buildBusinessModelsBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
5688
5804
|
}
|
|
5689
5805
|
],
|
|
5690
5806
|
skills: [
|
|
5691
|
-
buildScanBusinessModelsSkill(paths),
|
|
5692
|
-
buildCanvasBusinessModelSkill(paths),
|
|
5693
|
-
buildCompleteBusinessModelSkill(paths)
|
|
5807
|
+
buildScanBusinessModelsSkill(paths, issueDefaults),
|
|
5808
|
+
buildCanvasBusinessModelSkill(paths, issueDefaults),
|
|
5809
|
+
buildCompleteBusinessModelSkill(paths, issueDefaults)
|
|
5694
5810
|
],
|
|
5695
5811
|
subAgents: [buildBusinessModelsAnalystSubAgent(paths)],
|
|
5696
5812
|
labels: [
|
|
@@ -5720,7 +5836,7 @@ function buildBusinessModelsBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
5720
5836
|
var businessModelsBundle = buildBusinessModelsBundle();
|
|
5721
5837
|
|
|
5722
5838
|
// src/agent/bundles/company-profile.ts
|
|
5723
|
-
function buildCompanyProfileAnalystSubAgent(paths) {
|
|
5839
|
+
function buildCompanyProfileAnalystSubAgent(paths, issueDefaults) {
|
|
5724
5840
|
return {
|
|
5725
5841
|
name: "company-profile-analyst",
|
|
5726
5842
|
description: "Researches an external company (competitor, vendor, partner, customer, etc.) from public sources and produces a structured markdown profile, then enqueues downstream `people:research` and `software:research` issues for notable people and software products surfaced during profiling. Also handles profile enrichment against business-model canvases (`company:match`), maintenance refreshes on a configurable staleness cadence (`company:refresh`), and cross-profile competitive synthesis for a segment (`company:analyze`). One company or segment per session, tracked by company:* GitHub issue labels.",
|
|
@@ -6130,8 +6246,8 @@ function buildCompanyProfileAnalystSubAgent(paths) {
|
|
|
6130
6246
|
"",
|
|
6131
6247
|
" - `type:people-profile`",
|
|
6132
6248
|
" - `people:research`",
|
|
6133
|
-
|
|
6134
|
-
|
|
6249
|
+
` - \`priority:${labelsForPhase(issueDefaults, "people:research").priority}\``,
|
|
6250
|
+
` - \`status:${labelsForPhase(issueDefaults, "people:research").status}\``,
|
|
6135
6251
|
"",
|
|
6136
6252
|
" The issue body must include:",
|
|
6137
6253
|
" - A **discovery source** line naming this company profile",
|
|
@@ -6147,8 +6263,8 @@ function buildCompanyProfileAnalystSubAgent(paths) {
|
|
|
6147
6263
|
"",
|
|
6148
6264
|
" - `type:software-profile`",
|
|
6149
6265
|
" - `software:research`",
|
|
6150
|
-
|
|
6151
|
-
|
|
6266
|
+
` - \`priority:${labelsForPhase(issueDefaults, "software:research").priority}\``,
|
|
6267
|
+
` - \`status:${labelsForPhase(issueDefaults, "software:research").status}\``,
|
|
6152
6268
|
"",
|
|
6153
6269
|
" The issue body must include:",
|
|
6154
6270
|
" - A **discovery source** line naming this company profile",
|
|
@@ -6589,47 +6705,52 @@ function buildCompanyProfileAnalystSubAgent(paths) {
|
|
|
6589
6705
|
].join("\n")
|
|
6590
6706
|
};
|
|
6591
6707
|
}
|
|
6592
|
-
|
|
6593
|
-
|
|
6594
|
-
|
|
6595
|
-
|
|
6596
|
-
|
|
6597
|
-
|
|
6598
|
-
|
|
6599
|
-
|
|
6600
|
-
|
|
6601
|
-
|
|
6602
|
-
|
|
6603
|
-
|
|
6604
|
-
|
|
6605
|
-
|
|
6606
|
-
|
|
6607
|
-
|
|
6608
|
-
|
|
6609
|
-
|
|
6610
|
-
|
|
6611
|
-
|
|
6612
|
-
|
|
6613
|
-
|
|
6614
|
-
|
|
6615
|
-
|
|
6616
|
-
|
|
6617
|
-
|
|
6618
|
-
|
|
6619
|
-
|
|
6620
|
-
|
|
6621
|
-
|
|
6622
|
-
|
|
6623
|
-
|
|
6624
|
-
|
|
6625
|
-
|
|
6626
|
-
|
|
6627
|
-
|
|
6628
|
-
|
|
6629
|
-
|
|
6630
|
-
|
|
6631
|
-
|
|
6632
|
-
|
|
6708
|
+
function buildProfileCompanyEvalsJson(issueDefaults) {
|
|
6709
|
+
const research = labelsForPhase(issueDefaults, "company:research");
|
|
6710
|
+
return JSON.stringify(
|
|
6711
|
+
{
|
|
6712
|
+
skill_name: "profile-company",
|
|
6713
|
+
evals: [
|
|
6714
|
+
{
|
|
6715
|
+
id: 1,
|
|
6716
|
+
prompt: "/profile-company Acme Registration \u2014 they're a mid-market B2B event platform we ran into at a trade show last month. framing: competitive analysis for our self-service registration feature.",
|
|
6717
|
+
expected_output: `A \`company:research\` issue is created with \`type:company-profile\`, \`priority:${research.priority}\`, and \`status:${research.status}\`. The issue body carries the company name, an inferred or stated type (likely \`competitor\` given the framing), the framing text, and any supplied overrides. Phase 1 produces a research-notes file under the project's notes directory with sources annotated by tier (T1/T2/T3/T4) and date. Phase 2 opens a \`company:draft\` issue and may additionally open \`people:research\` issues for notable leaders surfaced and \`software:research\` issues for adjacent product mentions. The skill does not author person profiles, software profiles, or comparative analyses itself.`,
|
|
6718
|
+
files: [],
|
|
6719
|
+
product_context_refs: [
|
|
6720
|
+
"Mission",
|
|
6721
|
+
"Domain Vocabulary",
|
|
6722
|
+
"In-Scope Capabilities"
|
|
6723
|
+
]
|
|
6724
|
+
},
|
|
6725
|
+
{
|
|
6726
|
+
id: 2,
|
|
6727
|
+
prompt: "Profile a startup called Lumen Events. Their current company page lists a 150-person team but a TechCrunch article from six months ago said they were at 80 people. Handle the conflict.",
|
|
6728
|
+
expected_output: "The `company:research` issue body captures the conflict up-front under a dedicated conflict-resolution note. The research notes file annotates the live company page as a T1 living source and the TechCrunch article as a T3 secondary source. Conflict resolution follows the documented hierarchy: T1 wins on headcount (a fast-decay claim), so the current-state profile records 150 employees. The profile adds an inline note flagging that the T3 source is six months old and may simply be stale. Sources section lists each citation with tier, access date or publish date, and URL.",
|
|
6729
|
+
files: [],
|
|
6730
|
+
product_context_refs: ["Domain Vocabulary"]
|
|
6731
|
+
},
|
|
6732
|
+
{
|
|
6733
|
+
id: 3,
|
|
6734
|
+
prompt: "/profile-company Acme Registration \u2014 we already have a profile for them but it's nine months old. Refresh it.",
|
|
6735
|
+
expected_output: "The pipeline routes through the refresh phase (not a fresh profile). It reads the existing profile slug and refuses to create a second profile under a new slug. When the existing profile is younger than the configured staleness threshold and `force: true` is not set, the refresh phase exits early and appends a revision-history row noting the review. When the profile is past cadence (nine months qualifies for most fast-decay fields), the refresh updates fast-decay claims in place (headcount, leadership, pricing, product features) while preserving stable history, and appends a revision-history row citing what changed and which sources were re-checked. No new profile file is created.",
|
|
6736
|
+
files: [],
|
|
6737
|
+
product_context_refs: ["Domain Vocabulary"]
|
|
6738
|
+
}
|
|
6739
|
+
]
|
|
6740
|
+
},
|
|
6741
|
+
null,
|
|
6742
|
+
2
|
|
6743
|
+
);
|
|
6744
|
+
}
|
|
6745
|
+
function buildProfileCompanyReferenceFiles(issueDefaults) {
|
|
6746
|
+
return [
|
|
6747
|
+
{
|
|
6748
|
+
path: "evals/evals.json",
|
|
6749
|
+
content: buildProfileCompanyEvalsJson(issueDefaults)
|
|
6750
|
+
}
|
|
6751
|
+
];
|
|
6752
|
+
}
|
|
6753
|
+
function buildProfileCompanySkill(paths, issueDefaults) {
|
|
6633
6754
|
return {
|
|
6634
6755
|
name: "profile-company",
|
|
6635
6756
|
description: "Kick off a company-profile pipeline. Creates a company:research issue for the given company and dispatches Phase 1 (Research) in the company-profile-analyst agent.",
|
|
@@ -6638,7 +6759,7 @@ function buildProfileCompanySkill(paths) {
|
|
|
6638
6759
|
context: "fork",
|
|
6639
6760
|
agent: "company-profile-analyst",
|
|
6640
6761
|
platforms: { cursor: { exclude: true } },
|
|
6641
|
-
referenceFiles:
|
|
6762
|
+
referenceFiles: buildProfileCompanyReferenceFiles(issueDefaults),
|
|
6642
6763
|
instructions: [
|
|
6643
6764
|
"# Profile Company",
|
|
6644
6765
|
"",
|
|
@@ -6669,7 +6790,7 @@ function buildProfileCompanySkill(paths) {
|
|
|
6669
6790
|
"## Steps",
|
|
6670
6791
|
"",
|
|
6671
6792
|
"1. Create a `company:research` issue with `type:company-profile`,",
|
|
6672
|
-
|
|
6793
|
+
` \`priority:${labelsForPhase(issueDefaults, "company:research").priority}\`, and \`status:${labelsForPhase(issueDefaults, "company:research").status}\`. Body must include the`,
|
|
6673
6794
|
" company name, selected type, framing, and any overrides.",
|
|
6674
6795
|
"2. Execute Phase 1 (Research) of the company-profile-analyst agent.",
|
|
6675
6796
|
"3. Phase 1 creates the `company:draft` issue. Phase 2 may create a",
|
|
@@ -6693,7 +6814,7 @@ function buildProfileCompanySkill(paths) {
|
|
|
6693
6814
|
].join("\n")
|
|
6694
6815
|
};
|
|
6695
6816
|
}
|
|
6696
|
-
function buildMatchCompanySkill(paths) {
|
|
6817
|
+
function buildMatchCompanySkill(paths, issueDefaults) {
|
|
6697
6818
|
return {
|
|
6698
6819
|
name: "match-company",
|
|
6699
6820
|
description: "Kick off a company-profile match (enrichment) cycle. Creates a company:match issue for an existing profile and dispatches Phase 4 (Match) in the company-profile-analyst agent. Match enriches the profile with business-model, segment, and size context from existing docs \u2014 no web searches.",
|
|
@@ -6743,7 +6864,7 @@ function buildMatchCompanySkill(paths) {
|
|
|
6743
6864
|
"## Steps",
|
|
6744
6865
|
"",
|
|
6745
6866
|
"1. Create a `company:match` issue with `type:company-profile`,",
|
|
6746
|
-
|
|
6867
|
+
` \`priority:${labelsForPhase(issueDefaults, "company:match").priority}\`, and \`status:${labelsForPhase(issueDefaults, "company:match").status}\`. Body must include the`,
|
|
6747
6868
|
" profile path and any overrides.",
|
|
6748
6869
|
"2. Execute Phase 4 (Match) of the company-profile-analyst agent.",
|
|
6749
6870
|
"",
|
|
@@ -6758,7 +6879,7 @@ function buildMatchCompanySkill(paths) {
|
|
|
6758
6879
|
].join("\n")
|
|
6759
6880
|
};
|
|
6760
6881
|
}
|
|
6761
|
-
function buildRefreshCompanySkill(paths) {
|
|
6882
|
+
function buildRefreshCompanySkill(paths, issueDefaults) {
|
|
6762
6883
|
return {
|
|
6763
6884
|
name: "refresh-company",
|
|
6764
6885
|
description: "Kick off a company-profile refresh cycle. Creates a company:refresh issue for an existing profile and dispatches Phase 5 (Refresh) in the company-profile-analyst agent. Refresh re-verifies the profile with 4\u20136 targeted web searches and updates it in place. Respects a configurable staleness threshold so profiles younger than the threshold exit early.",
|
|
@@ -6816,7 +6937,7 @@ function buildRefreshCompanySkill(paths) {
|
|
|
6816
6937
|
"## Steps",
|
|
6817
6938
|
"",
|
|
6818
6939
|
"1. Create a `company:refresh` issue with `type:company-profile`,",
|
|
6819
|
-
|
|
6940
|
+
` \`priority:${labelsForPhase(issueDefaults, "company:refresh").priority}\`, and \`status:${labelsForPhase(issueDefaults, "company:refresh").status}\`. Body must include the`,
|
|
6820
6941
|
" profile path and any overrides.",
|
|
6821
6942
|
"2. Execute Phase 5 (Refresh) of the company-profile-analyst agent.",
|
|
6822
6943
|
"",
|
|
@@ -6832,7 +6953,7 @@ function buildRefreshCompanySkill(paths) {
|
|
|
6832
6953
|
].join("\n")
|
|
6833
6954
|
};
|
|
6834
6955
|
}
|
|
6835
|
-
function buildAnalyzeSegmentSkill(paths) {
|
|
6956
|
+
function buildAnalyzeSegmentSkill(paths, issueDefaults) {
|
|
6836
6957
|
return {
|
|
6837
6958
|
name: "analyze-segment",
|
|
6838
6959
|
description: "Kick off a segment-level competitive-analysis cycle. Creates a company:analyze issue for the target segment and dispatches Phase 6 (Analyze) in the company-profile-analyst agent. Analyze synthesizes every profile in the segment into one competitive-analysis document. Blocks on open company:draft issues for the segment.",
|
|
@@ -6889,7 +7010,7 @@ function buildAnalyzeSegmentSkill(paths) {
|
|
|
6889
7010
|
"## Steps",
|
|
6890
7011
|
"",
|
|
6891
7012
|
"1. Create a `company:analyze` issue with `type:company-profile`,",
|
|
6892
|
-
|
|
7013
|
+
` \`priority:${labelsForPhase(issueDefaults, "company:analyze").priority}\`, and \`status:${labelsForPhase(issueDefaults, "company:analyze").status}\`. Body must include the`,
|
|
6893
7014
|
" segment slug and any overrides.",
|
|
6894
7015
|
"2. Execute Phase 6 (Analyze) of the company-profile-analyst agent.",
|
|
6895
7016
|
"",
|
|
@@ -6906,7 +7027,7 @@ function buildAnalyzeSegmentSkill(paths) {
|
|
|
6906
7027
|
].join("\n")
|
|
6907
7028
|
};
|
|
6908
7029
|
}
|
|
6909
|
-
function buildCompanyProfileBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
7030
|
+
function buildCompanyProfileBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
6910
7031
|
return {
|
|
6911
7032
|
name: "company-profile",
|
|
6912
7033
|
description: "Company research and profiling pipeline: research, draft profile, followup, match, refresh, analyze. Enabled by default; domain-neutral; filesystem-durable between phases. Phase 3 (Followup) hands surfaced people and software products off to the `people-profile` and `software-profile` bundles via `people:research` and `software:research` issues. Phase 4 (Match) enriches profiles against business-model canvases. Phase 5 (Refresh) re-verifies profiles on a configurable staleness cadence. Phase 6 (Analyze) synthesizes profiles in a segment into a competitive-analysis document.",
|
|
@@ -6959,12 +7080,12 @@ function buildCompanyProfileBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
6959
7080
|
}
|
|
6960
7081
|
],
|
|
6961
7082
|
skills: [
|
|
6962
|
-
buildProfileCompanySkill(paths),
|
|
6963
|
-
buildMatchCompanySkill(paths),
|
|
6964
|
-
buildRefreshCompanySkill(paths),
|
|
6965
|
-
buildAnalyzeSegmentSkill(paths)
|
|
7083
|
+
buildProfileCompanySkill(paths, issueDefaults),
|
|
7084
|
+
buildMatchCompanySkill(paths, issueDefaults),
|
|
7085
|
+
buildRefreshCompanySkill(paths, issueDefaults),
|
|
7086
|
+
buildAnalyzeSegmentSkill(paths, issueDefaults)
|
|
6966
7087
|
],
|
|
6967
|
-
subAgents: [buildCompanyProfileAnalystSubAgent(paths)],
|
|
7088
|
+
subAgents: [buildCompanyProfileAnalystSubAgent(paths, issueDefaults)],
|
|
6968
7089
|
labels: [
|
|
6969
7090
|
{
|
|
6970
7091
|
name: "type:company-profile",
|
|
@@ -7144,7 +7265,7 @@ var CUSTOMER_PROFILE_REFERENCE_FILES = [
|
|
|
7144
7265
|
content: TEMPLATE_CUSTOMER_PROFILE
|
|
7145
7266
|
}
|
|
7146
7267
|
];
|
|
7147
|
-
function buildCustomerProfileAnalystSubAgent(paths) {
|
|
7268
|
+
function buildCustomerProfileAnalystSubAgent(paths, issueDefaults) {
|
|
7148
7269
|
return {
|
|
7149
7270
|
name: "customer-profile-analyst",
|
|
7150
7271
|
description: "Authors customer-archetype research through a 3-phase pipeline (discover \u2192 profile \u2192 competitors). Segments customer archetypes, profiles each archetype's goals, jobs-to-be-done, constraints, and buying process, then maps competitor features (from the shared software-profile feature matrix) to each archetype's needs and hands off unmet-need gaps to the requirements-analyst as req:scan seeds. One phase per session, tracked by customer:* GitHub issue labels with filesystem-based durability between phases.",
|
|
@@ -7468,12 +7589,23 @@ function buildCustomerProfileAnalystSubAgent(paths) {
|
|
|
7468
7589
|
" customer organizations that do not already have a canonical",
|
|
7469
7590
|
" profile or an open `company:research` issue. The",
|
|
7470
7591
|
" `company-profile` bundle owns the downstream profile; this",
|
|
7471
|
-
" agent only hands off.",
|
|
7592
|
+
" agent only hands off. Each issue must carry:",
|
|
7593
|
+
"",
|
|
7594
|
+
" - `type:company-profile`",
|
|
7595
|
+
" - `company:research`",
|
|
7596
|
+
` - \`priority:${labelsForPhase(issueDefaults, "company:research").priority}\``,
|
|
7597
|
+
` - \`status:${labelsForPhase(issueDefaults, "company:research").status}\``,
|
|
7472
7598
|
"",
|
|
7473
7599
|
"9. **Create `people:research` issues** for notable contacts",
|
|
7474
7600
|
" (economic buyers, technical buyers, user champions) surfaced in",
|
|
7475
7601
|
" sources. Keep the list small \u2014 at most three individuals per",
|
|
7476
7602
|
" profile session \u2014 and skip anyone already profiled or queued.",
|
|
7603
|
+
" Each issue must carry:",
|
|
7604
|
+
"",
|
|
7605
|
+
" - `type:people-profile`",
|
|
7606
|
+
" - `people:research`",
|
|
7607
|
+
` - \`priority:${labelsForPhase(issueDefaults, "people:research").priority}\``,
|
|
7608
|
+
` - \`status:${labelsForPhase(issueDefaults, "people:research").status}\``,
|
|
7477
7609
|
"",
|
|
7478
7610
|
"10. **Verify all handoffs were created** before committing.",
|
|
7479
7611
|
"",
|
|
@@ -7569,21 +7701,39 @@ function buildCustomerProfileAnalystSubAgent(paths) {
|
|
|
7569
7701
|
"7. **Create `req:scan` issues** for each unmet need. Each issue",
|
|
7570
7702
|
" hands off to the `requirements-analyst` bundle so its scan phase",
|
|
7571
7703
|
" can deduplicate and open `req:write` issues in the appropriate",
|
|
7572
|
-
" category. Each handoff issue
|
|
7573
|
-
"
|
|
7704
|
+
" category. Each handoff issue must carry:",
|
|
7705
|
+
"",
|
|
7706
|
+
" - `type:requirement`",
|
|
7707
|
+
" - `req:scan`",
|
|
7708
|
+
` - \`priority:${labelsForPhase(issueDefaults, "req:scan").priority}\``,
|
|
7709
|
+
` - \`status:${labelsForPhase(issueDefaults, "req:scan").status}\``,
|
|
7710
|
+
"",
|
|
7711
|
+
" The body must also:",
|
|
7574
7712
|
" - Link back to the archetype page and the competitor page",
|
|
7575
7713
|
" - Cite the specific unmet-need row and the originating job",
|
|
7576
|
-
" -
|
|
7577
|
-
" archetype is high-priority and the gap is a deal-breaker
|
|
7714
|
+
" - Escalate the priority above the bundle default when the",
|
|
7715
|
+
" archetype is high-priority and the gap is a deal-breaker",
|
|
7578
7716
|
"",
|
|
7579
7717
|
"8. **Create `company:research` issues** for competitor organizations",
|
|
7580
7718
|
" referenced in the analysis that do not already have a canonical",
|
|
7581
|
-
" profile or an open `company:research` issue.",
|
|
7719
|
+
" profile or an open `company:research` issue. Each issue must",
|
|
7720
|
+
" carry:",
|
|
7721
|
+
"",
|
|
7722
|
+
" - `type:company-profile`",
|
|
7723
|
+
" - `company:research`",
|
|
7724
|
+
` - \`priority:${labelsForPhase(issueDefaults, "company:research").priority}\``,
|
|
7725
|
+
` - \`status:${labelsForPhase(issueDefaults, "company:research").status}\``,
|
|
7582
7726
|
"",
|
|
7583
7727
|
"9. **Create `people:research` issues** for notable competitor",
|
|
7584
7728
|
" leadership or customer-advocacy figures surfaced in the analysis.",
|
|
7585
7729
|
" Keep this list small \u2014 at most three individuals per competitors",
|
|
7586
|
-
" session \u2014 and skip anyone already profiled or queued.",
|
|
7730
|
+
" session \u2014 and skip anyone already profiled or queued. Each",
|
|
7731
|
+
" issue must carry:",
|
|
7732
|
+
"",
|
|
7733
|
+
" - `type:people-profile`",
|
|
7734
|
+
" - `people:research`",
|
|
7735
|
+
` - \`priority:${labelsForPhase(issueDefaults, "people:research").priority}\``,
|
|
7736
|
+
` - \`status:${labelsForPhase(issueDefaults, "people:research").status}\``,
|
|
7587
7737
|
"",
|
|
7588
7738
|
"10. **Commit and push** the competitor-analysis page and the",
|
|
7589
7739
|
" updated archetype page. Close the competitors issue.",
|
|
@@ -7727,7 +7877,7 @@ function buildCustomerProfileAnalystSubAgent(paths) {
|
|
|
7727
7877
|
].join("\n")
|
|
7728
7878
|
};
|
|
7729
7879
|
}
|
|
7730
|
-
function buildDiscoverCustomersSkill(paths) {
|
|
7880
|
+
function buildDiscoverCustomersSkill(paths, issueDefaults) {
|
|
7731
7881
|
return {
|
|
7732
7882
|
name: "discover-customers",
|
|
7733
7883
|
description: "Kick off the discover phase of a customer-research campaign. Creates a customer:discover issue for the supplied scope (industry, segment, or the consuming project as a whole) and dispatches Phase 1 of the customer-profile-analyst, which scans existing documentation for archetype candidates, writes a discovery report, and creates downstream customer:profile issues.",
|
|
@@ -7769,7 +7919,7 @@ function buildDiscoverCustomersSkill(paths) {
|
|
|
7769
7919
|
"## Steps",
|
|
7770
7920
|
"",
|
|
7771
7921
|
"1. Create a `customer:discover` issue with `type:customer-profile`,",
|
|
7772
|
-
|
|
7922
|
+
` \`priority:${labelsForPhase(issueDefaults, "customer:discover").priority}\`, and \`status:${labelsForPhase(issueDefaults, "customer:discover").status}\`. The body must include the`,
|
|
7773
7923
|
" scope slug and any known archetypes to include or exclude.",
|
|
7774
7924
|
"2. Execute Phase 1 (Discover) of the customer-profile-analyst agent.",
|
|
7775
7925
|
"3. Phase 1 writes the discovery report and creates one",
|
|
@@ -7784,7 +7934,7 @@ function buildDiscoverCustomersSkill(paths) {
|
|
|
7784
7934
|
].join("\n")
|
|
7785
7935
|
};
|
|
7786
7936
|
}
|
|
7787
|
-
function buildProfileCustomerSkill(paths) {
|
|
7937
|
+
function buildProfileCustomerSkill(paths, issueDefaults) {
|
|
7788
7938
|
return {
|
|
7789
7939
|
name: "profile-customer",
|
|
7790
7940
|
description: "Kick off the profile phase for one customer archetype. Creates a customer:profile issue for the supplied archetype and dispatches Phase 2 of the customer-profile-analyst, which populates the archetype page with segment, goals, jobs-to-be-done, constraints, buying process, technology landscape, and regulatory applicability using the ship-with customer-profile-page template.",
|
|
@@ -7844,7 +7994,7 @@ function buildProfileCustomerSkill(paths) {
|
|
|
7844
7994
|
"## Steps",
|
|
7845
7995
|
"",
|
|
7846
7996
|
"1. Create a `customer:profile` issue with `type:customer-profile`,",
|
|
7847
|
-
|
|
7997
|
+
` \`priority:${labelsForPhase(issueDefaults, "customer:profile").priority}\`, and \`status:${labelsForPhase(issueDefaults, "customer:profile").status}\`. The body must include the`,
|
|
7848
7998
|
" archetype slug and (optionally) the segment slug.",
|
|
7849
7999
|
"2. Execute Phase 2 (Profile) of the customer-profile-analyst agent.",
|
|
7850
8000
|
" The agent runs 4\u20138 targeted web searches and populates the",
|
|
@@ -7864,7 +8014,7 @@ function buildProfileCustomerSkill(paths) {
|
|
|
7864
8014
|
].join("\n")
|
|
7865
8015
|
};
|
|
7866
8016
|
}
|
|
7867
|
-
function buildAnalyzeCustomerCompetitorsSkill(paths) {
|
|
8017
|
+
function buildAnalyzeCustomerCompetitorsSkill(paths, issueDefaults) {
|
|
7868
8018
|
return {
|
|
7869
8019
|
name: "analyze-customer-competitors",
|
|
7870
8020
|
description: "Kick off the competitors phase for one customer archetype. Creates a customer:competitors issue for the supplied archetype and dispatches Phase 3 of the customer-profile-analyst, which maps rows from the shared software-profile feature matrix to the archetype's needs, identifies unmet needs, and hands off each unmet need as a req:scan seed to the requirements-analyst bundle.",
|
|
@@ -7918,8 +8068,8 @@ function buildAnalyzeCustomerCompetitorsSkill(paths) {
|
|
|
7918
8068
|
"## Steps",
|
|
7919
8069
|
"",
|
|
7920
8070
|
"1. Create a `customer:competitors` issue with",
|
|
7921
|
-
|
|
7922
|
-
|
|
8071
|
+
` \`type:customer-profile\`, \`priority:${labelsForPhase(issueDefaults, "customer:competitors").priority}\`, and`,
|
|
8072
|
+
` \`status:${labelsForPhase(issueDefaults, "customer:competitors").status}\` (or \`status:blocked\` when still dependent on a`,
|
|
7923
8073
|
" Phase 2 profile issue). Body must include the archetype page",
|
|
7924
8074
|
" path.",
|
|
7925
8075
|
"2. Execute Phase 3 (Competitors) of the customer-profile-analyst",
|
|
@@ -7944,7 +8094,7 @@ function buildAnalyzeCustomerCompetitorsSkill(paths) {
|
|
|
7944
8094
|
].join("\n")
|
|
7945
8095
|
};
|
|
7946
8096
|
}
|
|
7947
|
-
function buildCustomerProfileBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
8097
|
+
function buildCustomerProfileBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
7948
8098
|
return {
|
|
7949
8099
|
name: "customer-profile",
|
|
7950
8100
|
description: "Customer-archetype research pipeline: discover, profile, competitors. 3 phases with customer:* phase labels. Segments customer archetypes, profiles each archetype's goals, jobs-to-be-done, constraints, and buying process, then maps competitor features (from the shared software-profile feature matrix) to each archetype's needs and hands off unmet-need gaps to the requirements-analyst bundle as req:scan seeds. Enabled by default; domain-neutral; customer-centric (distinct from company-profile); filesystem-durable between phases.",
|
|
@@ -8015,11 +8165,11 @@ function buildCustomerProfileBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
8015
8165
|
}
|
|
8016
8166
|
],
|
|
8017
8167
|
skills: [
|
|
8018
|
-
buildDiscoverCustomersSkill(paths),
|
|
8019
|
-
buildProfileCustomerSkill(paths),
|
|
8020
|
-
buildAnalyzeCustomerCompetitorsSkill(paths)
|
|
8168
|
+
buildDiscoverCustomersSkill(paths, issueDefaults),
|
|
8169
|
+
buildProfileCustomerSkill(paths, issueDefaults),
|
|
8170
|
+
buildAnalyzeCustomerCompetitorsSkill(paths, issueDefaults)
|
|
8021
8171
|
],
|
|
8022
|
-
subAgents: [buildCustomerProfileAnalystSubAgent(paths)],
|
|
8172
|
+
subAgents: [buildCustomerProfileAnalystSubAgent(paths, issueDefaults)],
|
|
8023
8173
|
labels: [
|
|
8024
8174
|
{
|
|
8025
8175
|
name: "type:customer-profile",
|
|
@@ -9225,7 +9375,7 @@ var githubWorkflowBundle = {
|
|
|
9225
9375
|
};
|
|
9226
9376
|
|
|
9227
9377
|
// src/agent/bundles/industry-discovery.ts
|
|
9228
|
-
function buildIndustryDiscoveryAnalystSubAgent(paths) {
|
|
9378
|
+
function buildIndustryDiscoveryAnalystSubAgent(paths, issueDefaults) {
|
|
9229
9379
|
return {
|
|
9230
9380
|
name: "industry-discovery-analyst",
|
|
9231
9381
|
description: "Discovers candidate industry verticals, scores each against a configurable capability/fit rubric, and creates planning issues for verticals that clear the threshold. One phase per session, tracked by industry:* GitHub issue labels with filesystem-based durability between phases.",
|
|
@@ -9563,8 +9713,8 @@ function buildIndustryDiscoveryAnalystSubAgent(paths) {
|
|
|
9563
9713
|
"4. **Create one `research:scope` issue per cleared vertical.** This",
|
|
9564
9714
|
" assumes the `research-pipeline` bundle is enabled in the consuming",
|
|
9565
9715
|
" project. Each downstream issue should:",
|
|
9566
|
-
|
|
9567
|
-
|
|
9716
|
+
` - Carry \`type:research\`, \`research:scope\`, \`priority:${labelsForPhase(issueDefaults, "research:scope").priority}\`, and`,
|
|
9717
|
+
` \`status:${labelsForPhase(issueDefaults, "research:scope").status}\` labels`,
|
|
9568
9718
|
" - Include the research question framed for the vertical (what the",
|
|
9569
9719
|
" downstream research needs to answer)",
|
|
9570
9720
|
" - Cite the evaluation row that justified advancing the vertical",
|
|
@@ -9615,7 +9765,7 @@ function buildIndustryDiscoveryAnalystSubAgent(paths) {
|
|
|
9615
9765
|
].join("\n")
|
|
9616
9766
|
};
|
|
9617
9767
|
}
|
|
9618
|
-
function buildDiscoverIndustriesSkill(paths) {
|
|
9768
|
+
function buildDiscoverIndustriesSkill(paths, issueDefaults) {
|
|
9619
9769
|
return {
|
|
9620
9770
|
name: "discover-industries",
|
|
9621
9771
|
description: "Kick off an industry-discovery pipeline. Creates an industry:discover issue carrying the discovery scope and dispatches Phase 1 (Discover) in the industry-discovery-analyst agent.",
|
|
@@ -9657,7 +9807,7 @@ function buildDiscoverIndustriesSkill(paths) {
|
|
|
9657
9807
|
"## Steps",
|
|
9658
9808
|
"",
|
|
9659
9809
|
"1. Create an `industry:discover` issue with `type:industry-discovery`,",
|
|
9660
|
-
|
|
9810
|
+
` \`priority:${labelsForPhase(issueDefaults, "industry:discover").priority}\`, and \`status:${labelsForPhase(issueDefaults, "industry:discover").status}\`. Body must include the`,
|
|
9661
9811
|
" verbatim scope, authorized sources, and any overrides.",
|
|
9662
9812
|
"2. Execute Phase 1 (Discover) of the industry-discovery-analyst",
|
|
9663
9813
|
" agent.",
|
|
@@ -9678,7 +9828,7 @@ function buildDiscoverIndustriesSkill(paths) {
|
|
|
9678
9828
|
].join("\n")
|
|
9679
9829
|
};
|
|
9680
9830
|
}
|
|
9681
|
-
function buildIndustryDiscoveryBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
9831
|
+
function buildIndustryDiscoveryBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
9682
9832
|
return {
|
|
9683
9833
|
name: "industry-discovery",
|
|
9684
9834
|
description: "Industry-vertical discovery pipeline: discover candidates, evaluate against a fit rubric, plan downstream research. Enabled by default; domain-neutral; filesystem-durable between phases.",
|
|
@@ -9712,8 +9862,8 @@ function buildIndustryDiscoveryBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
9712
9862
|
tags: ["workflow"]
|
|
9713
9863
|
}
|
|
9714
9864
|
],
|
|
9715
|
-
skills: [buildDiscoverIndustriesSkill(paths)],
|
|
9716
|
-
subAgents: [buildIndustryDiscoveryAnalystSubAgent(paths)],
|
|
9865
|
+
skills: [buildDiscoverIndustriesSkill(paths, issueDefaults)],
|
|
9866
|
+
subAgents: [buildIndustryDiscoveryAnalystSubAgent(paths, issueDefaults)],
|
|
9717
9867
|
labels: [
|
|
9718
9868
|
{
|
|
9719
9869
|
name: "type:industry-discovery",
|
|
@@ -10325,7 +10475,7 @@ function buildMaintenanceAuditSubAgent(paths) {
|
|
|
10325
10475
|
].join("\n")
|
|
10326
10476
|
};
|
|
10327
10477
|
}
|
|
10328
|
-
function buildMaintenanceAuditSkill(paths) {
|
|
10478
|
+
function buildMaintenanceAuditSkill(paths, issueDefaults) {
|
|
10329
10479
|
return {
|
|
10330
10480
|
name: "audit-docs",
|
|
10331
10481
|
description: "Kick off a documentation-maintenance audit cycle (scan \u2192 fix \u2192 verify). Creates a maint:scan issue for the supplied scope and dispatches Phase 1.",
|
|
@@ -10360,7 +10510,7 @@ function buildMaintenanceAuditSkill(paths) {
|
|
|
10360
10510
|
"## Steps",
|
|
10361
10511
|
"",
|
|
10362
10512
|
"1. Create a `maint:scan` issue with `type:maintenance`,",
|
|
10363
|
-
|
|
10513
|
+
` \`priority:${labelsForPhase(issueDefaults, "maint:scan").priority}\`, and \`status:${labelsForPhase(issueDefaults, "maint:scan").status}\`. Body must list:`,
|
|
10364
10514
|
" - `<DOCS_ROOT>` \u2014 the doc tree to audit",
|
|
10365
10515
|
" - `<AUDIT_ROOT>` \u2014 where to write the audit report",
|
|
10366
10516
|
" - `<AUDIT_SLUG>` \u2014 short identifier for this audit",
|
|
@@ -10382,7 +10532,7 @@ function buildMaintenanceAuditSkill(paths) {
|
|
|
10382
10532
|
].join("\n")
|
|
10383
10533
|
};
|
|
10384
10534
|
}
|
|
10385
|
-
function buildMaintenanceVerifySkill() {
|
|
10535
|
+
function buildMaintenanceVerifySkill(issueDefaults) {
|
|
10386
10536
|
return {
|
|
10387
10537
|
name: "verify-audit",
|
|
10388
10538
|
description: "Kick off the verify phase of a documentation-maintenance audit cycle. Creates a maint:verify issue that re-runs the scan checks scoped to the paths a fix phase touched, compares pre/post findings, and closes the parent maint:scan issue when clean or files a follow-up maint:scan for residual findings.",
|
|
@@ -10423,7 +10573,7 @@ function buildMaintenanceVerifySkill() {
|
|
|
10423
10573
|
"## Steps",
|
|
10424
10574
|
"",
|
|
10425
10575
|
"1. Create a `maint:verify` issue with `type:maintenance`,",
|
|
10426
|
-
|
|
10576
|
+
` \`priority:${labelsForPhase(issueDefaults, "maint:verify").priority}\`, and \`status:${labelsForPhase(issueDefaults, "maint:verify").status}\`. Body must list:`,
|
|
10427
10577
|
" - The parent `maint:scan` issue number",
|
|
10428
10578
|
" - The Phase 1 audit report path",
|
|
10429
10579
|
" - The Phase 2 fix report path (if one exists)",
|
|
@@ -10440,7 +10590,7 @@ function buildMaintenanceVerifySkill() {
|
|
|
10440
10590
|
].join("\n")
|
|
10441
10591
|
};
|
|
10442
10592
|
}
|
|
10443
|
-
function buildMaintenanceAuditBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
10593
|
+
function buildMaintenanceAuditBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
10444
10594
|
return {
|
|
10445
10595
|
name: "maintenance-audit",
|
|
10446
10596
|
description: "Documentation-maintenance agent bundle. 3-phase pipeline (scan, fix, verify) with maint:* phase labels for auditing registries and cross-references, applying idempotent fixes, and confirming the fixes cleared the originally-flagged findings. Enabled by default.",
|
|
@@ -10483,7 +10633,10 @@ function buildMaintenanceAuditBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
10483
10633
|
tags: ["workflow"]
|
|
10484
10634
|
}
|
|
10485
10635
|
],
|
|
10486
|
-
skills: [
|
|
10636
|
+
skills: [
|
|
10637
|
+
buildMaintenanceAuditSkill(paths, issueDefaults),
|
|
10638
|
+
buildMaintenanceVerifySkill(issueDefaults)
|
|
10639
|
+
],
|
|
10487
10640
|
subAgents: [buildMaintenanceAuditSubAgent(paths)],
|
|
10488
10641
|
labels: [
|
|
10489
10642
|
{
|
|
@@ -12892,80 +13045,81 @@ function buildCheckBlockedScript(tiers, scopeGate, runRatio) {
|
|
|
12892
13045
|
"}",
|
|
12893
13046
|
"",
|
|
12894
13047
|
"cmd_eligible() {",
|
|
12895
|
-
"
|
|
12896
|
-
|
|
12897
|
-
|
|
12898
|
-
|
|
12899
|
-
"",
|
|
12900
|
-
"
|
|
12901
|
-
|
|
12902
|
-
|
|
12903
|
-
|
|
12904
|
-
"
|
|
12905
|
-
"
|
|
13048
|
+
" # Bucketed scan: walk priority levels critical \u2192 high \u2192 medium \u2192 low \u2192",
|
|
13049
|
+
" # trivial, fetching one bucket at a time. The first bucket with at",
|
|
13050
|
+
" # least one survivor (after the Depends-on filter) short-circuits the",
|
|
13051
|
+
" # loop \u2014 lower-priority buckets are never queried in the common case.",
|
|
13052
|
+
" # This guarantees that every higher-priority issue is visible even",
|
|
13053
|
+
" # when the global ready backlog exceeds 50, at the cost of up to one",
|
|
13054
|
+
" # extra `gh issue list` call per empty bucket above the first hit.",
|
|
13055
|
+
" local level",
|
|
13056
|
+
" for level in critical high medium low trivial; do",
|
|
13057
|
+
" local issues",
|
|
13058
|
+
' issues=$(gh issue list --label "status:ready" --label "priority:${level}" --state open \\',
|
|
13059
|
+
' --search "sort:created-asc" \\',
|
|
13060
|
+
' --json number,title,body,labels --limit 50 2>/dev/null || echo "[]")',
|
|
13061
|
+
"",
|
|
13062
|
+
" local count",
|
|
13063
|
+
` count=$(echo "$issues" | jq 'length')`,
|
|
13064
|
+
' if [[ "$count" -eq 0 ]]; then',
|
|
13065
|
+
" continue",
|
|
13066
|
+
" fi",
|
|
12906
13067
|
"",
|
|
12907
|
-
"
|
|
12908
|
-
`
|
|
12909
|
-
"
|
|
12910
|
-
'
|
|
12911
|
-
'
|
|
12912
|
-
'
|
|
12913
|
-
'
|
|
12914
|
-
" ')",
|
|
13068
|
+
" local issue_data",
|
|
13069
|
+
` issue_data=$(echo "$issues" | jq -r '`,
|
|
13070
|
+
" .[] |",
|
|
13071
|
+
' (.body | split("\\n") | map(select(test("Depends on:"; "i"))) | .[0] // "") as $dep_line |',
|
|
13072
|
+
' (.labels | map(.name) | map(select(startswith("type:"))) | .[0] // "") as $type_label |',
|
|
13073
|
+
' "\\(.number)\\t\\(.title)\\t\\($dep_line)\\t\\($type_label)"',
|
|
13074
|
+
" ')",
|
|
12915
13075
|
"",
|
|
12916
|
-
'
|
|
12917
|
-
"
|
|
12918
|
-
'
|
|
13076
|
+
' local results=""',
|
|
13077
|
+
" while IFS=$'\\t' read -r num title dep_line type_label; do",
|
|
13078
|
+
' [[ -z "$num" ]] && continue',
|
|
12919
13079
|
"",
|
|
12920
|
-
'
|
|
12921
|
-
'
|
|
12922
|
-
'
|
|
12923
|
-
"
|
|
13080
|
+
' local deps=""',
|
|
13081
|
+
' if [[ -n "$dep_line" ]]; then',
|
|
13082
|
+
' deps=$(parse_deps "$dep_line")',
|
|
13083
|
+
" fi",
|
|
12924
13084
|
"",
|
|
12925
|
-
"
|
|
12926
|
-
"
|
|
12927
|
-
'
|
|
12928
|
-
'
|
|
12929
|
-
"
|
|
12930
|
-
'
|
|
12931
|
-
"
|
|
12932
|
-
'
|
|
12933
|
-
"
|
|
12934
|
-
"
|
|
12935
|
-
"
|
|
13085
|
+
" # Check if any dep is still open.",
|
|
13086
|
+
" local has_open_dep=false",
|
|
13087
|
+
' local open_deps=""',
|
|
13088
|
+
' if [[ -n "${deps// /}" ]]; then',
|
|
13089
|
+
" for dep in $deps; do",
|
|
13090
|
+
' if ! is_closed "$dep"; then',
|
|
13091
|
+
" has_open_dep=true",
|
|
13092
|
+
' open_deps="${open_deps}#${dep} "',
|
|
13093
|
+
" fi",
|
|
13094
|
+
" done",
|
|
13095
|
+
" fi",
|
|
12936
13096
|
"",
|
|
12937
|
-
"
|
|
12938
|
-
'
|
|
12939
|
-
"
|
|
12940
|
-
"
|
|
13097
|
+
" if $has_open_dep; then",
|
|
13098
|
+
' echo "SKIP #${num} \u2014 dep ${open_deps% } still open"',
|
|
13099
|
+
" continue",
|
|
13100
|
+
" fi",
|
|
12941
13101
|
"",
|
|
12942
|
-
"
|
|
12943
|
-
|
|
12944
|
-
|
|
12945
|
-
'
|
|
12946
|
-
' *priority:critical*) priority_key=0; priority="critical" ;;',
|
|
12947
|
-
' *priority:high*) priority_key=1; priority="high" ;;',
|
|
12948
|
-
' *priority:medium*) priority_key=2; priority="medium" ;;',
|
|
12949
|
-
' *priority:low*) priority_key=3; priority="low" ;;',
|
|
12950
|
-
' *priority:trivial*) priority_key=4; priority="trivial" ;;',
|
|
12951
|
-
" esac",
|
|
13102
|
+
" # Funnel-tier sort key (0-4; 0 dispatches first within a bucket).",
|
|
13103
|
+
' local type_value="${type_label#type:}"',
|
|
13104
|
+
" local tier_key",
|
|
13105
|
+
' tier_key=$(tier_of "$type_value")',
|
|
12952
13106
|
"",
|
|
12953
|
-
|
|
12954
|
-
'
|
|
12955
|
-
" local tier_key",
|
|
12956
|
-
' tier_key=$(tier_of "$type_value")',
|
|
13107
|
+
' local label_info=""',
|
|
13108
|
+
' [[ -n "$type_label" ]] && label_info=" ${type_label}"',
|
|
12957
13109
|
"",
|
|
12958
|
-
'
|
|
12959
|
-
'
|
|
13110
|
+
' results="${results}${tier_key}\\t${num}\\tPICK #${num} priority:${level} tier:${tier_key}${label_info} \\"${title}\\"\\n"',
|
|
13111
|
+
' done <<< "$issue_data"',
|
|
12960
13112
|
"",
|
|
12961
|
-
|
|
12962
|
-
|
|
13113
|
+
" # Within this bucket: sort by funnel tier asc \u2192 issue number asc",
|
|
13114
|
+
" # (FIFO). If any PICK lines survived the Depends-on filter, emit",
|
|
13115
|
+
" # them and short-circuit before querying lower-priority buckets.",
|
|
13116
|
+
' if [[ -n "$results" ]]; then',
|
|
13117
|
+
` printf '%b' "$results" | sort -t$'\\t' -k1,1n -k2,2n | cut -f3`,
|
|
13118
|
+
" return 0",
|
|
13119
|
+
" fi",
|
|
13120
|
+
" done",
|
|
12963
13121
|
"",
|
|
12964
|
-
|
|
12965
|
-
" # (asc, lower tier wins on priority tie), then issue number (FIFO).",
|
|
12966
|
-
' if [[ -n "$results" ]]; then',
|
|
12967
|
-
` printf '%b' "$results" | sort -t$'\\t' -k1,1n -k2,2n -k3,3n | cut -f4`,
|
|
12968
|
-
" fi",
|
|
13122
|
+
' echo "NO_READY_ISSUES"',
|
|
12969
13123
|
"}",
|
|
12970
13124
|
"",
|
|
12971
13125
|
"cmd_stale() {",
|
|
@@ -13400,9 +13554,25 @@ var orchestratorSubAgent = {
|
|
|
13400
13554
|
".claude/procedures/check-blocked.sh eligible",
|
|
13401
13555
|
"```",
|
|
13402
13556
|
"",
|
|
13557
|
+
"The script walks the priority buckets **critical \u2192 high \u2192 medium \u2192 low",
|
|
13558
|
+
"\u2192 trivial** in order, querying one bucket at a time and short-circuiting",
|
|
13559
|
+
"on the first non-empty bucket whose survivors clear the `Depends on:`",
|
|
13560
|
+
"filter. Each bucket is fetched with",
|
|
13561
|
+
'`gh issue list --label "status:ready" --label "priority:<level>" --limit 50`,',
|
|
13562
|
+
"so every higher-priority issue is visible even when the global ready",
|
|
13563
|
+
"backlog exceeds 50 \u2014 a `priority:critical` filing can never be hidden",
|
|
13564
|
+
"behind 50 older medium/low issues. The cost in the common case (the",
|
|
13565
|
+
"first bucket the script queries is non-empty) is **one `gh issue list`",
|
|
13566
|
+
"call**, identical to the previous single-fetch implementation; the",
|
|
13567
|
+
"worst case is five calls when every higher-priority bucket is empty",
|
|
13568
|
+
"or fully dep-blocked. Per-priority bucket size is still capped at 50",
|
|
13569
|
+
"issues \u2014 see the **Orchestrator Conventions** section in `CLAUDE.md`.",
|
|
13570
|
+
"",
|
|
13403
13571
|
"The script emits `PICK` lines sorted by **priority desc \u2192 funnel tier asc",
|
|
13404
|
-
"\u2192 issue number asc
|
|
13405
|
-
"
|
|
13572
|
+
"\u2192 issue number asc** (priority order is enforced by the bucket walk;",
|
|
13573
|
+
"the in-bucket sort handles funnel tier and FIFO). Each line carries",
|
|
13574
|
+
"both `priority:<level>` and `tier:<n>` so the sort is legible at a",
|
|
13575
|
+
"glance:",
|
|
13406
13576
|
"",
|
|
13407
13577
|
"```",
|
|
13408
13578
|
'PICK #42 priority:high tier:1 type:research "FHIR extension analysis"',
|
|
@@ -14033,7 +14203,7 @@ var ORCHESTRATOR_CONVENTIONS_PREAMBLE = [
|
|
|
14033
14203
|
"- The orchestrator **never** implements code, creates branches, pushes commits, **or merges PRs** \u2014 it triages issues, picks the next work item, and delegates implementation to other sub-agents. Approved-PR merging is owned by the `pr-reviewer` sub-agent (invoked via `/review-pr` / `/review-prs`).",
|
|
14034
14204
|
"- All triage queries use `.claude/procedures/check-blocked.sh` for token efficiency",
|
|
14035
14205
|
"- 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.",
|
|
14036
|
-
"- Priority order: critical > high > medium > low > trivial, then **funnel tier asc** (lower tier wins ties), then FIFO by issue number",
|
|
14206
|
+
"- Priority order: critical > high > medium > low > trivial, then **funnel tier asc** (lower tier wins ties), then FIFO by issue number. Phase E's queue scan walks each priority bucket in turn (one `gh issue list` call per bucket, **capped at 50 issues per bucket**) and short-circuits on the first bucket whose survivors clear the `Depends on:` filter, so every higher-priority issue is visible even when the global ready backlog is much larger than 50.",
|
|
14037
14207
|
"- Stale thresholds: 72h for in-progress, 168h for blocked",
|
|
14038
14208
|
"- Flagged issues get `status:needs-attention` \u2014 they are not auto-reset",
|
|
14039
14209
|
"",
|
|
@@ -14120,7 +14290,7 @@ var orchestratorBundle = {
|
|
|
14120
14290
|
};
|
|
14121
14291
|
|
|
14122
14292
|
// src/agent/bundles/people-profile.ts
|
|
14123
|
-
function buildPeopleProfileAnalystSubAgent(paths) {
|
|
14293
|
+
function buildPeopleProfileAnalystSubAgent(paths, issueDefaults) {
|
|
14124
14294
|
return {
|
|
14125
14295
|
name: "people-profile-analyst",
|
|
14126
14296
|
description: "Researches an individual person (colleague, customer contact, vendor contact, partner contact, industry expert, or connector) from public sources and produces a structured markdown profile cross-linked to companies, software, and meeting notes, then enqueues downstream `company:research` and `software:research` issues for unprofiled companies and software products surfaced during profiling. Also handles maintenance refreshes on a configurable staleness cadence (`people:refresh`). One person per session, tracked by people:* GitHub issue labels.",
|
|
@@ -14557,8 +14727,8 @@ function buildPeopleProfileAnalystSubAgent(paths) {
|
|
|
14557
14727
|
"",
|
|
14558
14728
|
" - `type:company-profile`",
|
|
14559
14729
|
" - `company:research`",
|
|
14560
|
-
|
|
14561
|
-
|
|
14730
|
+
` - \`priority:${labelsForPhase(issueDefaults, "company:research").priority}\``,
|
|
14731
|
+
` - \`status:${labelsForPhase(issueDefaults, "company:research").status}\``,
|
|
14562
14732
|
"",
|
|
14563
14733
|
" The issue body must include:",
|
|
14564
14734
|
" - A **discovery source** line naming this person profile",
|
|
@@ -14577,8 +14747,8 @@ function buildPeopleProfileAnalystSubAgent(paths) {
|
|
|
14577
14747
|
"",
|
|
14578
14748
|
" - `type:software-profile`",
|
|
14579
14749
|
" - `software:research`",
|
|
14580
|
-
|
|
14581
|
-
|
|
14750
|
+
` - \`priority:${labelsForPhase(issueDefaults, "software:research").priority}\``,
|
|
14751
|
+
` - \`status:${labelsForPhase(issueDefaults, "software:research").status}\``,
|
|
14582
14752
|
"",
|
|
14583
14753
|
" The issue body must include:",
|
|
14584
14754
|
" - A **discovery source** line naming this person profile",
|
|
@@ -14797,7 +14967,7 @@ function buildPeopleProfileAnalystSubAgent(paths) {
|
|
|
14797
14967
|
].join("\n")
|
|
14798
14968
|
};
|
|
14799
14969
|
}
|
|
14800
|
-
function buildProfilePersonSkill(paths) {
|
|
14970
|
+
function buildProfilePersonSkill(paths, issueDefaults) {
|
|
14801
14971
|
return {
|
|
14802
14972
|
name: "profile-person",
|
|
14803
14973
|
description: "Kick off a people-profile pipeline. Creates a people:research issue for the given person and dispatches Phase 1 (Research) in the people-profile-analyst agent. Phase 3 (Followup) enqueues downstream `company:research` and `software:research` issues for unprofiled, genuinely-relevant entities surfaced in the profile.",
|
|
@@ -14848,7 +15018,7 @@ function buildProfilePersonSkill(paths) {
|
|
|
14848
15018
|
"## Steps",
|
|
14849
15019
|
"",
|
|
14850
15020
|
"1. Create a `people:research` issue with `type:people-profile`,",
|
|
14851
|
-
|
|
15021
|
+
` \`priority:${labelsForPhase(issueDefaults, "people:research").priority}\`, and \`status:${labelsForPhase(issueDefaults, "people:research").status}\`. Body must include the`,
|
|
14852
15022
|
" person's name, selected role, primary company, framing, and any",
|
|
14853
15023
|
" overrides.",
|
|
14854
15024
|
"2. Execute Phase 1 (Research) of the people-profile-analyst agent.",
|
|
@@ -14873,7 +15043,7 @@ function buildProfilePersonSkill(paths) {
|
|
|
14873
15043
|
].join("\n")
|
|
14874
15044
|
};
|
|
14875
15045
|
}
|
|
14876
|
-
function buildRefreshPersonSkill(paths) {
|
|
15046
|
+
function buildRefreshPersonSkill(paths, issueDefaults) {
|
|
14877
15047
|
return {
|
|
14878
15048
|
name: "refresh-person",
|
|
14879
15049
|
description: "Kick off a people-profile refresh cycle. Creates a people:refresh issue for an existing profile and dispatches Phase 4 (Refresh) in the people-profile-analyst agent. Refresh re-verifies the profile's narrow delta set (role, employer, primary public channel) with 3\u20135 targeted web searches and updates it in place. Respects a configurable staleness threshold so profiles younger than the threshold exit early.",
|
|
@@ -14940,7 +15110,7 @@ function buildRefreshPersonSkill(paths) {
|
|
|
14940
15110
|
"## Steps",
|
|
14941
15111
|
"",
|
|
14942
15112
|
"1. Create a `people:refresh` issue with `type:people-profile`,",
|
|
14943
|
-
|
|
15113
|
+
` \`priority:${labelsForPhase(issueDefaults, "people:refresh").priority}\`, and \`status:${labelsForPhase(issueDefaults, "people:refresh").status}\`. Body must include the`,
|
|
14944
15114
|
" profile path and any overrides.",
|
|
14945
15115
|
"2. Execute Phase 4 (Refresh) of the people-profile-analyst agent.",
|
|
14946
15116
|
"",
|
|
@@ -14954,7 +15124,7 @@ function buildRefreshPersonSkill(paths) {
|
|
|
14954
15124
|
].join("\n")
|
|
14955
15125
|
};
|
|
14956
15126
|
}
|
|
14957
|
-
function buildPeopleProfileBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
15127
|
+
function buildPeopleProfileBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
14958
15128
|
return {
|
|
14959
15129
|
name: "people-profile",
|
|
14960
15130
|
description: "People research and profiling pipeline: research, draft profile, followup, refresh. Enabled by default; domain-neutral; filesystem-durable between phases. Cross-references existing companies, software, and meeting notes, and Phase 3 (Followup) hands unprofiled, genuinely-relevant companies and software products off to the `company-profile` and `software-profile` bundles via `company:research` and `software:research` issues. Phase 4 (Refresh) re-verifies profiles on a configurable staleness cadence.",
|
|
@@ -14998,8 +15168,11 @@ function buildPeopleProfileBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
14998
15168
|
tags: ["workflow"]
|
|
14999
15169
|
}
|
|
15000
15170
|
],
|
|
15001
|
-
skills: [
|
|
15002
|
-
|
|
15171
|
+
skills: [
|
|
15172
|
+
buildProfilePersonSkill(paths, issueDefaults),
|
|
15173
|
+
buildRefreshPersonSkill(paths, issueDefaults)
|
|
15174
|
+
],
|
|
15175
|
+
subAgents: [buildPeopleProfileAnalystSubAgent(paths, issueDefaults)],
|
|
15003
15176
|
labels: [
|
|
15004
15177
|
{
|
|
15005
15178
|
name: "type:people-profile",
|
|
@@ -17164,7 +17337,7 @@ var REGULATORY_RESEARCH_REFERENCE_FILES = [
|
|
|
17164
17337
|
content: TEMPLATE_REGULATION
|
|
17165
17338
|
}
|
|
17166
17339
|
];
|
|
17167
|
-
function buildRegulatoryResearchAnalystSubAgent(paths) {
|
|
17340
|
+
function buildRegulatoryResearchAnalystSubAgent(paths, issueDefaults) {
|
|
17168
17341
|
return {
|
|
17169
17342
|
name: "regulatory-research-analyst",
|
|
17170
17343
|
description: "Authors jurisdictional compliance research through a 3-phase pipeline (scan \u2192 research \u2192 impact). Enumerates applicable regulations by jurisdiction and business activity, researches each in depth, and produces an impact analysis that hands off actionable obligations to the requirements-analyst as req:scan seeds in the SEC category. One phase per session, tracked by regulatory:* GitHub issue labels with filesystem-based durability between phases.",
|
|
@@ -17519,6 +17692,12 @@ function buildRegulatoryResearchAnalystSubAgent(paths) {
|
|
|
17519
17692
|
" regulator agencies that do not already have a canonical profile",
|
|
17520
17693
|
" or an open `company:research` issue. The `company-profile`",
|
|
17521
17694
|
" bundle owns the downstream profile; this agent only hands off.",
|
|
17695
|
+
" Each issue must carry:",
|
|
17696
|
+
"",
|
|
17697
|
+
" - `type:company-profile`",
|
|
17698
|
+
" - `company:research`",
|
|
17699
|
+
` - \`priority:${labelsForPhase(issueDefaults, "company:research").priority}\``,
|
|
17700
|
+
` - \`status:${labelsForPhase(issueDefaults, "company:research").status}\``,
|
|
17522
17701
|
"",
|
|
17523
17702
|
"9. **Verify all handoffs were created** before committing.",
|
|
17524
17703
|
"",
|
|
@@ -17587,25 +17766,42 @@ function buildRegulatoryResearchAnalystSubAgent(paths) {
|
|
|
17587
17766
|
"4. **Create `req:scan` issues** for each capability gap identified.",
|
|
17588
17767
|
" Each issue hands off to the `requirements-analyst` bundle so its",
|
|
17589
17768
|
" scan phase can deduplicate and open `req:write` issues in the",
|
|
17590
|
-
" SEC category.
|
|
17591
|
-
"
|
|
17769
|
+
" SEC category. Each issue must carry:",
|
|
17770
|
+
"",
|
|
17771
|
+
" - `type:requirement`",
|
|
17772
|
+
" - `req:scan`",
|
|
17773
|
+
` - \`priority:${labelsForPhase(issueDefaults, "req:scan").priority}\``,
|
|
17774
|
+
` - \`status:${labelsForPhase(issueDefaults, "req:scan").status}\``,
|
|
17775
|
+
"",
|
|
17776
|
+
" The body must also:",
|
|
17592
17777
|
" - Identify the target category as **SEC** (security & compliance)",
|
|
17593
17778
|
" in the body so the downstream writer phase picks up the right",
|
|
17594
17779
|
" template",
|
|
17595
17780
|
" - Link back to the regulation page and cite the triggering",
|
|
17596
17781
|
" requirement",
|
|
17597
|
-
" -
|
|
17598
|
-
" regulation is already in force and the gap is unmitigated
|
|
17782
|
+
" - Escalate the priority above the bundle default when the",
|
|
17783
|
+
" regulation is already in force and the gap is unmitigated",
|
|
17599
17784
|
"",
|
|
17600
17785
|
"5. **Create `company:research` issues** for any enforcement body",
|
|
17601
17786
|
" mentioned on the regulation page that does not already have a",
|
|
17602
|
-
" canonical profile or an open `company:research` issue.",
|
|
17787
|
+
" canonical profile or an open `company:research` issue. Each",
|
|
17788
|
+
" issue must carry:",
|
|
17789
|
+
"",
|
|
17790
|
+
" - `type:company-profile`",
|
|
17791
|
+
" - `company:research`",
|
|
17792
|
+
` - \`priority:${labelsForPhase(issueDefaults, "company:research").priority}\``,
|
|
17793
|
+
` - \`status:${labelsForPhase(issueDefaults, "company:research").status}\``,
|
|
17603
17794
|
"",
|
|
17604
17795
|
"6. **Create `people:research` issues** for notable regulatory",
|
|
17605
17796
|
" leaders (commissioners, agency directors, lead policy authors)",
|
|
17606
17797
|
" mentioned on the regulation page. Keep this list small \u2014 at most",
|
|
17607
17798
|
" three individuals per impact session \u2014 and skip anyone already",
|
|
17608
|
-
" profiled or queued.",
|
|
17799
|
+
" profiled or queued. Each issue must carry:",
|
|
17800
|
+
"",
|
|
17801
|
+
" - `type:people-profile`",
|
|
17802
|
+
" - `people:research`",
|
|
17803
|
+
` - \`priority:${labelsForPhase(issueDefaults, "people:research").priority}\``,
|
|
17804
|
+
` - \`status:${labelsForPhase(issueDefaults, "people:research").status}\``,
|
|
17609
17805
|
"",
|
|
17610
17806
|
"7. **Commit and push** the updated regulation page. Close the",
|
|
17611
17807
|
" impact issue.",
|
|
@@ -17724,7 +17920,7 @@ function buildRegulatoryResearchAnalystSubAgent(paths) {
|
|
|
17724
17920
|
].join("\n")
|
|
17725
17921
|
};
|
|
17726
17922
|
}
|
|
17727
|
-
function buildScanRegulatoryLandscapeSkill(paths) {
|
|
17923
|
+
function buildScanRegulatoryLandscapeSkill(paths, issueDefaults) {
|
|
17728
17924
|
return {
|
|
17729
17925
|
name: "scan-regulatory-landscape",
|
|
17730
17926
|
description: "Kick off the scan phase of a regulatory-research campaign. Creates a regulatory:scan issue for the supplied scope (industry, jurisdiction, or platform) and dispatches Phase 1 of the regulatory-research-analyst, which writes a scan report and creates downstream regulatory:research issues.",
|
|
@@ -17771,7 +17967,7 @@ function buildScanRegulatoryLandscapeSkill(paths) {
|
|
|
17771
17967
|
"## Steps",
|
|
17772
17968
|
"",
|
|
17773
17969
|
"1. Create a `regulatory:scan` issue with `type:regulatory-research`,",
|
|
17774
|
-
|
|
17970
|
+
` \`priority:${labelsForPhase(issueDefaults, "regulatory:scan").priority}\`, and \`status:${labelsForPhase(issueDefaults, "regulatory:scan").status}\`. The body must include the`,
|
|
17775
17971
|
" scope slug, the scope type, and any known regulations to include",
|
|
17776
17972
|
" or exclude.",
|
|
17777
17973
|
"2. Execute Phase 1 (Scan) of the regulatory-research-analyst agent.",
|
|
@@ -17788,7 +17984,7 @@ function buildScanRegulatoryLandscapeSkill(paths) {
|
|
|
17788
17984
|
].join("\n")
|
|
17789
17985
|
};
|
|
17790
17986
|
}
|
|
17791
|
-
function buildResearchRegulationSkill(paths) {
|
|
17987
|
+
function buildResearchRegulationSkill(paths, issueDefaults) {
|
|
17792
17988
|
return {
|
|
17793
17989
|
name: "research-regulation",
|
|
17794
17990
|
description: "Kick off the research phase for one regulation. Creates a regulatory:research issue for the supplied scope and regulation and dispatches Phase 2 of the regulatory-research-analyst, which populates the regulation page with scope, triggers, key requirements, jurisdiction variations, enforcement, and penalties using the ship-with regulation-page template.",
|
|
@@ -17847,8 +18043,8 @@ function buildResearchRegulationSkill(paths) {
|
|
|
17847
18043
|
"## Steps",
|
|
17848
18044
|
"",
|
|
17849
18045
|
"1. Create a `regulatory:research` issue with",
|
|
17850
|
-
|
|
17851
|
-
|
|
18046
|
+
` \`type:regulatory-research\`, \`priority:${labelsForPhase(issueDefaults, "regulatory:research").priority}\`, and`,
|
|
18047
|
+
` \`status:${labelsForPhase(issueDefaults, "regulatory:research").status}\`. The body must include the scope slug and the`,
|
|
17852
18048
|
" regulation slug.",
|
|
17853
18049
|
"2. Execute Phase 2 (Research) of the regulatory-research-analyst",
|
|
17854
18050
|
" agent. The agent runs 6\u201312 targeted web searches and populates",
|
|
@@ -17866,7 +18062,7 @@ function buildResearchRegulationSkill(paths) {
|
|
|
17866
18062
|
].join("\n")
|
|
17867
18063
|
};
|
|
17868
18064
|
}
|
|
17869
|
-
function buildImpactRegulationSkill(paths) {
|
|
18065
|
+
function buildImpactRegulationSkill(paths, issueDefaults) {
|
|
17870
18066
|
return {
|
|
17871
18067
|
name: "impact-regulation",
|
|
17872
18068
|
description: "Kick off the impact phase for one regulation. Creates a regulatory:impact issue for the supplied regulation and dispatches Phase 3 of the regulatory-research-analyst, which assesses product impact, documents capability gaps, and hands off each actionable obligation as a req:scan seed in the SEC (security & compliance) category for the requirements-analyst bundle to consume.",
|
|
@@ -17913,8 +18109,8 @@ function buildImpactRegulationSkill(paths) {
|
|
|
17913
18109
|
"## Steps",
|
|
17914
18110
|
"",
|
|
17915
18111
|
"1. Create a `regulatory:impact` issue with",
|
|
17916
|
-
|
|
17917
|
-
|
|
18112
|
+
` \`type:regulatory-research\`, \`priority:${labelsForPhase(issueDefaults, "regulatory:impact").priority}\`, and`,
|
|
18113
|
+
` \`status:${labelsForPhase(issueDefaults, "regulatory:impact").status}\` (or \`status:blocked\` when still dependent on a`,
|
|
17918
18114
|
" Phase 2 research issue). Body must include the regulation page",
|
|
17919
18115
|
" path.",
|
|
17920
18116
|
"2. Execute Phase 3 (Impact) of the regulatory-research-analyst",
|
|
@@ -17935,7 +18131,7 @@ function buildImpactRegulationSkill(paths) {
|
|
|
17935
18131
|
].join("\n")
|
|
17936
18132
|
};
|
|
17937
18133
|
}
|
|
17938
|
-
function buildRegulatoryResearchBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
18134
|
+
function buildRegulatoryResearchBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
17939
18135
|
return {
|
|
17940
18136
|
name: "regulatory-research",
|
|
17941
18137
|
description: "Regulatory compliance research pipeline: scan, research, impact. 3 phases with regulatory:* phase labels. Enumerates jurisdictional regulations by industry and activity, researches each in depth with specific section citations, and hands off actionable obligations to the requirements-analyst bundle as req:scan seeds that become SEC (security & compliance) requirements. Enabled by default; domain-neutral; documents obligations without interpreting them; filesystem-durable between phases.",
|
|
@@ -18002,11 +18198,11 @@ function buildRegulatoryResearchBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
18002
18198
|
}
|
|
18003
18199
|
],
|
|
18004
18200
|
skills: [
|
|
18005
|
-
buildScanRegulatoryLandscapeSkill(paths),
|
|
18006
|
-
buildResearchRegulationSkill(paths),
|
|
18007
|
-
buildImpactRegulationSkill(paths)
|
|
18201
|
+
buildScanRegulatoryLandscapeSkill(paths, issueDefaults),
|
|
18202
|
+
buildResearchRegulationSkill(paths, issueDefaults),
|
|
18203
|
+
buildImpactRegulationSkill(paths, issueDefaults)
|
|
18008
18204
|
],
|
|
18009
|
-
subAgents: [buildRegulatoryResearchAnalystSubAgent(paths)],
|
|
18205
|
+
subAgents: [buildRegulatoryResearchAnalystSubAgent(paths, issueDefaults)],
|
|
18010
18206
|
labels: [
|
|
18011
18207
|
{
|
|
18012
18208
|
name: "type:regulatory-research",
|
|
@@ -18134,7 +18330,7 @@ var REQ_WRITE_ISSUE_SCHEMA_SECTION = [
|
|
|
18134
18330
|
];
|
|
18135
18331
|
|
|
18136
18332
|
// src/agent/bundles/requirements-analyst.ts
|
|
18137
|
-
function buildRequirementsAnalystSubAgent(paths) {
|
|
18333
|
+
function buildRequirementsAnalystSubAgent(paths, issueDefaults) {
|
|
18138
18334
|
return {
|
|
18139
18335
|
name: "requirements-analyst",
|
|
18140
18336
|
description: "Discovers requirement gaps from BCM model docs, competitive analysis, product docs, and meeting extracts. Produces scan reports, proposals, and req:write issues for the downstream requirements-writer agent. Runs through a 2-phase pipeline (scan \u2192 draft-trace), one phase per session, tracked by req:* GitHub issue labels.",
|
|
@@ -18452,14 +18648,14 @@ function buildRequirementsAnalystSubAgent(paths) {
|
|
|
18452
18648
|
" `## Template: req:write` of",
|
|
18453
18649
|
" `docs/src/content/docs/agents/issue-templates.md`.",
|
|
18454
18650
|
"",
|
|
18455
|
-
|
|
18651
|
+
` All \`type:requirement\` issues default to \`priority:${labelsForPhase(issueDefaults, "req:write").priority}\` (override`,
|
|
18456
18652
|
" only if the proposal's priority was explicitly High or Low). Each",
|
|
18457
18653
|
" issue must also carry the `req:write` phase label plus the matching",
|
|
18458
18654
|
" `tier:*` label so the downstream `requirements-writer` bundle picks",
|
|
18459
18655
|
" it up with the correct tier. Concretely, the label list includes",
|
|
18460
18656
|
' `--label "type:requirement"`, `--label "req:write"`,',
|
|
18461
|
-
|
|
18462
|
-
|
|
18657
|
+
` \`--label "tier:<tier-slug>"\`, \`--label "status:${labelsForPhase(issueDefaults, "req:write").status}"\`, and`,
|
|
18658
|
+
` \`--label "priority:${labelsForPhase(issueDefaults, "req:write").priority}"\`.`,
|
|
18463
18659
|
"",
|
|
18464
18660
|
" The body must carry the three writer-required fields in an",
|
|
18465
18661
|
" `## Objective` block, written as bold-prefixed lines so the",
|
|
@@ -18476,7 +18672,7 @@ function buildRequirementsAnalystSubAgent(paths) {
|
|
|
18476
18672
|
"",
|
|
18477
18673
|
" When one of Category / Tier / Output Path could not be derived",
|
|
18478
18674
|
" from the proposal (for example, the proposal omitted the Tier",
|
|
18479
|
-
|
|
18675
|
+
` line), replace \`status:${labelsForPhase(issueDefaults, "req:write").status}\` with \`status:needs-attention\` in`,
|
|
18480
18676
|
" the label list and add a `Missing: <field> \u2014 <reason>` line",
|
|
18481
18677
|
" directly below the Output Path line in the body. Populate",
|
|
18482
18678
|
" whichever of the three fields **could** be derived so a human",
|
|
@@ -18542,48 +18738,50 @@ function buildRequirementsAnalystSubAgent(paths) {
|
|
|
18542
18738
|
].join("\n")
|
|
18543
18739
|
};
|
|
18544
18740
|
}
|
|
18545
|
-
|
|
18546
|
-
|
|
18547
|
-
|
|
18548
|
-
|
|
18549
|
-
|
|
18550
|
-
|
|
18551
|
-
|
|
18552
|
-
|
|
18553
|
-
|
|
18554
|
-
|
|
18555
|
-
|
|
18556
|
-
|
|
18557
|
-
|
|
18558
|
-
|
|
18559
|
-
|
|
18560
|
-
|
|
18561
|
-
|
|
18562
|
-
|
|
18563
|
-
|
|
18564
|
-
|
|
18565
|
-
|
|
18566
|
-
|
|
18567
|
-
|
|
18568
|
-
|
|
18569
|
-
|
|
18570
|
-
|
|
18571
|
-
|
|
18572
|
-
|
|
18573
|
-
|
|
18574
|
-
|
|
18575
|
-
|
|
18576
|
-
|
|
18577
|
-
|
|
18578
|
-
|
|
18579
|
-
|
|
18580
|
-
|
|
18581
|
-
|
|
18582
|
-
|
|
18583
|
-
|
|
18584
|
-
|
|
18585
|
-
|
|
18586
|
-
|
|
18741
|
+
function buildScanRequirementsSkill(issueDefaults) {
|
|
18742
|
+
return {
|
|
18743
|
+
name: "scan-requirements",
|
|
18744
|
+
description: "Kick off a requirements-analyst scan across BCM model docs, competitive analysis, product docs, or meeting extracts. Creates a req:scan issue and dispatches Phase 1.",
|
|
18745
|
+
disableModelInvocation: true,
|
|
18746
|
+
userInvocable: true,
|
|
18747
|
+
context: "fork",
|
|
18748
|
+
agent: "requirements-analyst",
|
|
18749
|
+
platforms: { cursor: { exclude: true } },
|
|
18750
|
+
instructions: [
|
|
18751
|
+
"# Scan Requirements",
|
|
18752
|
+
"",
|
|
18753
|
+
"Kick off a requirements-analyst scan cycle. Creates a `req:scan` issue",
|
|
18754
|
+
"targeted at the requested scope and dispatches Phase 1 (Scan) in the",
|
|
18755
|
+
"requirements-analyst agent.",
|
|
18756
|
+
"",
|
|
18757
|
+
"## Usage",
|
|
18758
|
+
"",
|
|
18759
|
+
"/scan-requirements <scope>",
|
|
18760
|
+
"",
|
|
18761
|
+
"Where `<scope>` is one of:",
|
|
18762
|
+
"- `bcm:<PREFIX-NNN>` \u2014 a single BCM model doc",
|
|
18763
|
+
"- `competitive:<slug>` \u2014 a single competitive analysis doc",
|
|
18764
|
+
"- `product-roadmap` \u2014 the prioritized feature roadmap",
|
|
18765
|
+
"- `entity-taxonomy` \u2014 the entity taxonomy doc",
|
|
18766
|
+
"- `meeting:<slug>` \u2014 a meeting extract",
|
|
18767
|
+
"- `all-bcm` / `all-competitive` \u2014 full sweep (long-running)",
|
|
18768
|
+
"",
|
|
18769
|
+
"## Steps",
|
|
18770
|
+
"",
|
|
18771
|
+
`1. Create a \`req:scan\` issue with \`type:requirement\`, \`priority:${labelsForPhase(issueDefaults, "req:scan").priority}\`,`,
|
|
18772
|
+
` and \`status:${labelsForPhase(issueDefaults, "req:scan").status}\`. Body must list the files to read and the scan scope.`,
|
|
18773
|
+
"2. Execute Phase 1 (Scan) of the requirements-analyst agent.",
|
|
18774
|
+
"3. If gaps are found, a `req:draft-trace` issue is created automatically.",
|
|
18775
|
+
"",
|
|
18776
|
+
"## Output",
|
|
18777
|
+
"",
|
|
18778
|
+
"- A `req-scan-<scope>-<YYYY-MM-DD>.md` file under the project's research",
|
|
18779
|
+
" requirements directory.",
|
|
18780
|
+
"- A `req:draft-trace` issue if any gaps were identified."
|
|
18781
|
+
].join("\n")
|
|
18782
|
+
};
|
|
18783
|
+
}
|
|
18784
|
+
function buildRequirementsAnalystBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
18587
18785
|
return {
|
|
18588
18786
|
name: "requirements-analyst",
|
|
18589
18787
|
description: "Requirements gap-discovery agent bundle for BCM-driven projects. 2-phase pipeline (scan, draft-trace) with req:* phase labels.",
|
|
@@ -18620,8 +18818,8 @@ function buildRequirementsAnalystBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
18620
18818
|
tags: ["workflow"]
|
|
18621
18819
|
}
|
|
18622
18820
|
],
|
|
18623
|
-
skills: [
|
|
18624
|
-
subAgents: [buildRequirementsAnalystSubAgent(paths)],
|
|
18821
|
+
skills: [buildScanRequirementsSkill(issueDefaults)],
|
|
18822
|
+
subAgents: [buildRequirementsAnalystSubAgent(paths, issueDefaults)],
|
|
18625
18823
|
labels: [
|
|
18626
18824
|
{
|
|
18627
18825
|
name: "type:requirement",
|
|
@@ -21122,7 +21320,7 @@ function buildRequirementsWriterSubAgent(paths) {
|
|
|
21122
21320
|
].join("\n")
|
|
21123
21321
|
};
|
|
21124
21322
|
}
|
|
21125
|
-
function buildWriteRequirementSkill(paths) {
|
|
21323
|
+
function buildWriteRequirementSkill(paths, issueDefaults) {
|
|
21126
21324
|
return {
|
|
21127
21325
|
name: WRITE_REQUIREMENT_SKILL_NAME,
|
|
21128
21326
|
description: "Write one formal requirement document (BR / FR / NFR / TR / ADR / SEC / DR / INT / OPS / UX / MT) using the shipped category template and decision-authority rules. Picks up a req:write issue created by the upstream requirements-analyst pipeline (or kicked off ad hoc) and dispatches the requirements-writer agent.",
|
|
@@ -21176,7 +21374,7 @@ function buildWriteRequirementSkill(paths) {
|
|
|
21176
21374
|
"## Steps",
|
|
21177
21375
|
"",
|
|
21178
21376
|
"1. Create a `req:write` issue with `type:requirement`,",
|
|
21179
|
-
|
|
21377
|
+
` \`priority:${labelsForPhase(issueDefaults, "req:write").priority}\`, \`status:${labelsForPhase(issueDefaults, "req:write").status}\`, and the matching \`tier:*\` label.`,
|
|
21180
21378
|
" Body must include the category, tier, output path, and a pointer",
|
|
21181
21379
|
" to the upstream proposal (or a direct user description if no",
|
|
21182
21380
|
" proposals file exists).",
|
|
@@ -21195,7 +21393,7 @@ function buildWriteRequirementSkill(paths) {
|
|
|
21195
21393
|
].join("\n")
|
|
21196
21394
|
};
|
|
21197
21395
|
}
|
|
21198
|
-
function buildRequirementsWriterBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
21396
|
+
function buildRequirementsWriterBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
21199
21397
|
return {
|
|
21200
21398
|
name: "requirements-writer",
|
|
21201
21399
|
description: "Requirements writer agent bundle. Authors formal requirement documents from upstream proposals using the 11-category taxonomy (BR, FR, NFR, TR, ADR, SEC, DR, INT, OPS, UX, MT), the four-tier classification, and decision-authority rules (direct-write vs. propose-only). Ships 13 templates plus a standards-and-frameworks reference.",
|
|
@@ -21243,7 +21441,7 @@ function buildRequirementsWriterBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
21243
21441
|
tags: ["workflow"]
|
|
21244
21442
|
}
|
|
21245
21443
|
],
|
|
21246
|
-
skills: [buildWriteRequirementSkill(paths)],
|
|
21444
|
+
skills: [buildWriteRequirementSkill(paths, issueDefaults)],
|
|
21247
21445
|
subAgents: [buildRequirementsWriterSubAgent(paths)],
|
|
21248
21446
|
labels: [
|
|
21249
21447
|
{
|
|
@@ -21277,7 +21475,7 @@ function buildRequirementsWriterBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
21277
21475
|
var requirementsWriterBundle = buildRequirementsWriterBundle();
|
|
21278
21476
|
|
|
21279
21477
|
// src/agent/bundles/requirements-reviewer.ts
|
|
21280
|
-
function buildRequirementsReviewerSubAgent(paths) {
|
|
21478
|
+
function buildRequirementsReviewerSubAgent(paths, issueDefaults) {
|
|
21281
21479
|
return {
|
|
21282
21480
|
name: "requirements-reviewer",
|
|
21283
21481
|
description: "Audits and deprecates existing requirement documents (BR, FR, NFR, TR, ADR, SEC, DR, INT, OPS, UX, MT). In `req:review` mode, runs the 12-check audit (structural compliance, categorization, traceability, cross-reference integrity, sequence integrity, content quality, registry sync, decision-authority compliance, tier classification, cross-referencing conventions, stale `Proposed` ADR/TR decisions) and produces a report grouped by Critical / Warning / Info (plus a dedicated Stale decisions section). In `req:deprecate` mode, transitions target documents to `Deprecated` or `Superseded`, updates the category index row, and files `req:write` follow-ups for every back-reference so the writer can rewrite them. One phase per session.",
|
|
@@ -22242,7 +22440,7 @@ function buildRequirementsReviewerSubAgent(paths) {
|
|
|
22242
22440
|
" reference).",
|
|
22243
22441
|
"- Labels: `type:requirement`, `req:write`, the matching",
|
|
22244
22442
|
" `tier:*` label derived from the referencing document's Tier,",
|
|
22245
|
-
|
|
22443
|
+
` \`priority:${labelsForPhase(issueDefaults, "req:write").priority}\`, \`status:${labelsForPhase(issueDefaults, "req:write").status}\`.`,
|
|
22246
22444
|
"- If any of Category / Tier / Output Path cannot be derived from",
|
|
22247
22445
|
" the referencing document, open the follow-up with",
|
|
22248
22446
|
" `status:needs-attention` and a `Missing:` line, per the same",
|
|
@@ -22332,7 +22530,7 @@ function buildRequirementsReviewerSubAgent(paths) {
|
|
|
22332
22530
|
].join("\n")
|
|
22333
22531
|
};
|
|
22334
22532
|
}
|
|
22335
|
-
function buildReviewRequirementsSkill(paths) {
|
|
22533
|
+
function buildReviewRequirementsSkill(paths, issueDefaults) {
|
|
22336
22534
|
return {
|
|
22337
22535
|
name: "review-requirements",
|
|
22338
22536
|
description: "Audit existing requirement documents (BR / FR / NFR / TR / ADR / SEC / DR / INT / OPS / UX / MT) for structural compliance, categorization, traceability, cross-reference integrity, sequence integrity, content quality, registry sync, decision-authority compliance, tier classification, cross-referencing conventions, and stale `Proposed` ADR/TR decisions. Supports four scopes (full audit, category, single document, targeted check) and dispatches the requirements-reviewer agent. Audits documents \u2014 never writes them. Soft dependency: expects requirement templates at `" + REQUIREMENTS_WRITER_PATHS.templatesRoot + "`, shipped by the requirements-writer bundle.",
|
|
@@ -22395,7 +22593,7 @@ function buildReviewRequirementsSkill(paths) {
|
|
|
22395
22593
|
"## Steps",
|
|
22396
22594
|
"",
|
|
22397
22595
|
"1. Create a `req:review` issue with `type:requirement`,",
|
|
22398
|
-
|
|
22596
|
+
` \`priority:${labelsForPhase(issueDefaults, "req:review").priority}\`, and \`status:${labelsForPhase(issueDefaults, "req:review").status}\`. Body must include the`,
|
|
22399
22597
|
" scope, the requirements root (or accept the default), and the",
|
|
22400
22598
|
" output path.",
|
|
22401
22599
|
"2. Execute the review phase of the requirements-reviewer agent.",
|
|
@@ -22434,7 +22632,7 @@ function buildReviewRequirementsSkill(paths) {
|
|
|
22434
22632
|
].join("\n")
|
|
22435
22633
|
};
|
|
22436
22634
|
}
|
|
22437
|
-
function buildDeprecateRequirementSkill(_paths) {
|
|
22635
|
+
function buildDeprecateRequirementSkill(_paths, issueDefaults) {
|
|
22438
22636
|
return {
|
|
22439
22637
|
name: "deprecate-requirement",
|
|
22440
22638
|
description: "Transition one or more requirement documents to `Deprecated` or `Superseded`. Creates a `req:deprecate` issue and dispatches the requirements-reviewer agent's deprecation phase, which edits the target document's Status, Revision History, Superseded-by traceability link, and category index row, then files `req:write` follow-ups for every back-reference so the requirements-writer can rewrite them. The deprecation phase pauses for explicit human confirmation before editing (unless the issue body pre-approves the change).",
|
|
@@ -22497,7 +22695,7 @@ function buildDeprecateRequirementSkill(_paths) {
|
|
|
22497
22695
|
"## Steps",
|
|
22498
22696
|
"",
|
|
22499
22697
|
"1. Create a `req:deprecate` issue with `type:requirement`,",
|
|
22500
|
-
|
|
22698
|
+
` \`priority:${labelsForPhase(issueDefaults, "req:deprecate").priority}\`, and \`status:${labelsForPhase(issueDefaults, "req:deprecate").status}\`. Body must include the`,
|
|
22501
22699
|
" Targets, Transition, and Reason sections above (optionally",
|
|
22502
22700
|
" `Pre-approved: yes`).",
|
|
22503
22701
|
"2. Execute the deprecation phase of the requirements-reviewer",
|
|
@@ -22538,7 +22736,7 @@ function buildDeprecateRequirementSkill(_paths) {
|
|
|
22538
22736
|
].join("\n")
|
|
22539
22737
|
};
|
|
22540
22738
|
}
|
|
22541
|
-
function buildRequirementsReviewerBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
22739
|
+
function buildRequirementsReviewerBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
22542
22740
|
return {
|
|
22543
22741
|
name: "requirements-reviewer",
|
|
22544
22742
|
description: "Requirements reviewer agent bundle. Audits existing requirement documents (BR, FR, NFR, TR, ADR, SEC, DR, INT, OPS, UX, MT) via the 12-check review phase (including Check 12: stale `Proposed` ADR/TR decisions), and transitions requirements to `Deprecated` or `Superseded` via the deprecation phase (narrow writes to Status, Revision History, Superseded-by, and category index row, with `req:write` follow-ups for every back-reference). Reads templates from the requirements-writer bundle's reference directory; ships no templates of its own.",
|
|
@@ -22651,10 +22849,10 @@ function buildRequirementsReviewerBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
22651
22849
|
}
|
|
22652
22850
|
],
|
|
22653
22851
|
skills: [
|
|
22654
|
-
buildReviewRequirementsSkill(paths),
|
|
22655
|
-
buildDeprecateRequirementSkill(paths)
|
|
22852
|
+
buildReviewRequirementsSkill(paths, issueDefaults),
|
|
22853
|
+
buildDeprecateRequirementSkill(paths, issueDefaults)
|
|
22656
22854
|
],
|
|
22657
|
-
subAgents: [buildRequirementsReviewerSubAgent(paths)],
|
|
22855
|
+
subAgents: [buildRequirementsReviewerSubAgent(paths, issueDefaults)],
|
|
22658
22856
|
labels: [
|
|
22659
22857
|
{
|
|
22660
22858
|
name: "req:review",
|
|
@@ -23028,7 +23226,7 @@ function buildResearchAnalystSubAgent(paths) {
|
|
|
23028
23226
|
].join("\n")
|
|
23029
23227
|
};
|
|
23030
23228
|
}
|
|
23031
|
-
function buildResearchSkill(paths) {
|
|
23229
|
+
function buildResearchSkill(paths, issueDefaults) {
|
|
23032
23230
|
return {
|
|
23033
23231
|
name: "research",
|
|
23034
23232
|
description: "Kick off a generic research micro-task pipeline. Creates a research:scope issue and dispatches Phase 1 (Scope) in the research-analyst agent.",
|
|
@@ -23068,7 +23266,7 @@ function buildResearchSkill(paths) {
|
|
|
23068
23266
|
"## Steps",
|
|
23069
23267
|
"",
|
|
23070
23268
|
"1. Create a `research:scope` issue with `type:research`,",
|
|
23071
|
-
|
|
23269
|
+
` \`priority:${labelsForPhase(issueDefaults, "research:scope").priority}\`, and \`status:${labelsForPhase(issueDefaults, "research:scope").status}\`. Body must include the`,
|
|
23072
23270
|
" verbatim question, authorized sources, and any overrides.",
|
|
23073
23271
|
"2. Execute Phase 1 (Scope) of the research-analyst agent.",
|
|
23074
23272
|
"3. Phase 1 creates `research:slice` issues (one per slice) and a",
|
|
@@ -23086,7 +23284,7 @@ function buildResearchSkill(paths) {
|
|
|
23086
23284
|
].join("\n")
|
|
23087
23285
|
};
|
|
23088
23286
|
}
|
|
23089
|
-
function buildResearchPipelineBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
23287
|
+
function buildResearchPipelineBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
23090
23288
|
return {
|
|
23091
23289
|
name: "research-pipeline",
|
|
23092
23290
|
description: "Generic research micro-task pipeline: scope, N-way slice search/synthesize, and verify. Enabled by default; domain-neutral; filesystem-durable between phases.",
|
|
@@ -23119,7 +23317,7 @@ function buildResearchPipelineBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
23119
23317
|
tags: ["workflow"]
|
|
23120
23318
|
}
|
|
23121
23319
|
],
|
|
23122
|
-
skills: [buildResearchSkill(paths)],
|
|
23320
|
+
skills: [buildResearchSkill(paths, issueDefaults)],
|
|
23123
23321
|
subAgents: [buildResearchAnalystSubAgent(paths)],
|
|
23124
23322
|
labels: [
|
|
23125
23323
|
{
|
|
@@ -23308,7 +23506,7 @@ var slackBundle = {
|
|
|
23308
23506
|
};
|
|
23309
23507
|
|
|
23310
23508
|
// src/agent/bundles/software-profile.ts
|
|
23311
|
-
function buildSoftwareProfileAnalystSubAgent(paths) {
|
|
23509
|
+
function buildSoftwareProfileAnalystSubAgent(paths, issueDefaults) {
|
|
23312
23510
|
return {
|
|
23313
23511
|
name: "software-profile-analyst",
|
|
23314
23512
|
description: "Researches a software product (competitor, adjacent, incumbent, enabler, infrastructure, or ecosystem-tool) from public sources, produces a structured markdown profile, contributes rows to a shared feature matrix ranked against configurable segment-importance weights, maps features back to the BCM capability model and flags unmapped features, then enqueues downstream `bcm:outline`, `company:research`, and `people:research` issues for new sub-capabilities, the vendor company, and primary-attribution founders/leaders surfaced during profiling. One product per session, tracked by software:* GitHub issue labels.",
|
|
@@ -23847,8 +24045,8 @@ function buildSoftwareProfileAnalystSubAgent(paths) {
|
|
|
23847
24045
|
"",
|
|
23848
24046
|
" - `type:bcm-document`",
|
|
23849
24047
|
" - `bcm:outline`",
|
|
23850
|
-
|
|
23851
|
-
|
|
24048
|
+
` - \`priority:${labelsForPhase(issueDefaults, "bcm:outline").priority}\``,
|
|
24049
|
+
` - \`status:${labelsForPhase(issueDefaults, "bcm:outline").status}\``,
|
|
23852
24050
|
"",
|
|
23853
24051
|
" The issue body must include:",
|
|
23854
24052
|
" - A **discovery source** line naming this software profile",
|
|
@@ -23916,7 +24114,7 @@ function buildSoftwareProfileAnalystSubAgent(paths) {
|
|
|
23916
24114
|
" `Follow-up Candidates > Adjacent products to evaluate`. Each new",
|
|
23917
24115
|
" issue follows the same 4-phase pipeline \u2014 start it in the",
|
|
23918
24116
|
" `software:research` phase with `type:software-profile`,",
|
|
23919
|
-
|
|
24117
|
+
` \`priority:${labelsForPhase(issueDefaults, "software:research").priority}\`, and \`status:${labelsForPhase(issueDefaults, "software:research").status}\`.`,
|
|
23920
24118
|
"",
|
|
23921
24119
|
"3. **Enqueue a `company:research` issue for the vendor company** if",
|
|
23922
24120
|
" no matching profile already exists under `<COMPANY_PROFILES_DIR>/`.",
|
|
@@ -23927,8 +24125,8 @@ function buildSoftwareProfileAnalystSubAgent(paths) {
|
|
|
23927
24125
|
"",
|
|
23928
24126
|
" - `type:company-profile`",
|
|
23929
24127
|
" - `company:research`",
|
|
23930
|
-
|
|
23931
|
-
|
|
24128
|
+
` - \`priority:${labelsForPhase(issueDefaults, "company:research").priority}\``,
|
|
24129
|
+
` - \`status:${labelsForPhase(issueDefaults, "company:research").status}\``,
|
|
23932
24130
|
"",
|
|
23933
24131
|
" The issue body must include:",
|
|
23934
24132
|
" - A **discovery source** line naming this software profile",
|
|
@@ -23946,8 +24144,8 @@ function buildSoftwareProfileAnalystSubAgent(paths) {
|
|
|
23946
24144
|
"",
|
|
23947
24145
|
" - `type:people-profile`",
|
|
23948
24146
|
" - `people:research`",
|
|
23949
|
-
|
|
23950
|
-
|
|
24147
|
+
` - \`priority:${labelsForPhase(issueDefaults, "people:research").priority}\``,
|
|
24148
|
+
` - \`status:${labelsForPhase(issueDefaults, "people:research").status}\``,
|
|
23951
24149
|
"",
|
|
23952
24150
|
" The issue body must include:",
|
|
23953
24151
|
" - A **discovery source** line naming this software profile",
|
|
@@ -24090,7 +24288,7 @@ function buildSoftwareProfileAnalystSubAgent(paths) {
|
|
|
24090
24288
|
].join("\n")
|
|
24091
24289
|
};
|
|
24092
24290
|
}
|
|
24093
|
-
function buildProfileSoftwareSkill(paths) {
|
|
24291
|
+
function buildProfileSoftwareSkill(paths, issueDefaults) {
|
|
24094
24292
|
return {
|
|
24095
24293
|
name: "profile-software",
|
|
24096
24294
|
description: "Kick off a software-profile pipeline. Creates a software:research issue for the given product and dispatches Phase 1 (Research) in the software-profile-analyst agent. Phase 4 (Map) writes a BCM capability mapping onto the profile and enqueues `bcm:outline` issues for unmapped features. Phase 5 (Followup) enqueues downstream `company:research` and `people:research` issues for the vendor company and primary-attribution founders/leaders surfaced in the profile.",
|
|
@@ -24137,7 +24335,7 @@ function buildProfileSoftwareSkill(paths) {
|
|
|
24137
24335
|
"## Steps",
|
|
24138
24336
|
"",
|
|
24139
24337
|
"1. Create a `software:research` issue with `type:software-profile`,",
|
|
24140
|
-
|
|
24338
|
+
` \`priority:${labelsForPhase(issueDefaults, "software:research").priority}\`, and \`status:${labelsForPhase(issueDefaults, "software:research").status}\`. Body must include the`,
|
|
24141
24339
|
" product name, selected type, framing, and any overrides.",
|
|
24142
24340
|
"2. Execute Phase 1 (Research) of the software-profile-analyst",
|
|
24143
24341
|
" agent.",
|
|
@@ -24170,7 +24368,7 @@ function buildProfileSoftwareSkill(paths) {
|
|
|
24170
24368
|
].join("\n")
|
|
24171
24369
|
};
|
|
24172
24370
|
}
|
|
24173
|
-
function buildMapSoftwareSkill(paths) {
|
|
24371
|
+
function buildMapSoftwareSkill(paths, issueDefaults) {
|
|
24174
24372
|
return {
|
|
24175
24373
|
name: "map-software",
|
|
24176
24374
|
description: "Kick off a standalone software-capability mapping session. Creates a software:map issue for an already-profiled product and dispatches Phase 4 (Map) in the software-profile-analyst agent. Produces the `## Capability Mapping` section on the profile and enqueues `bcm:outline` issues for unmapped features above the configured threshold.",
|
|
@@ -24225,7 +24423,7 @@ function buildMapSoftwareSkill(paths) {
|
|
|
24225
24423
|
"## Steps",
|
|
24226
24424
|
"",
|
|
24227
24425
|
"1. Create a `software:map` issue with `type:software-profile`,",
|
|
24228
|
-
|
|
24426
|
+
` \`priority:${labelsForPhase(issueDefaults, "software:map").priority}\`, and \`status:${labelsForPhase(issueDefaults, "software:map").status}\`. Body must include the`,
|
|
24229
24427
|
" profile path and any overrides.",
|
|
24230
24428
|
"2. Execute Phase 4 (Map) of the software-profile-analyst agent.",
|
|
24231
24429
|
"3. Phase 4 writes the `## Capability Mapping` section, enqueues",
|
|
@@ -24247,7 +24445,7 @@ function buildMapSoftwareSkill(paths) {
|
|
|
24247
24445
|
].join("\n")
|
|
24248
24446
|
};
|
|
24249
24447
|
}
|
|
24250
|
-
function buildSoftwareProfileBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
24448
|
+
function buildSoftwareProfileBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
24251
24449
|
return {
|
|
24252
24450
|
name: "software-profile",
|
|
24253
24451
|
description: "Software research, profiling, feature-matrix, and capability-mapping pipeline: research, profile, matrix, map, followup. Enabled by default; domain-neutral; filesystem-durable between phases; ranks features against configurable segment-importance weights and maps features back to the BCM capability model. Phase 4 (Map) hands unmapped features off to the `bcm-writer` bundle via `bcm:outline` issues. Phase 5 (Followup) hands the vendor company and primary-attribution founders/leaders off to the `company-profile` and `people-profile` bundles via `company:research` and `people:research` issues.",
|
|
@@ -24300,8 +24498,11 @@ function buildSoftwareProfileBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
24300
24498
|
tags: ["workflow"]
|
|
24301
24499
|
}
|
|
24302
24500
|
],
|
|
24303
|
-
skills: [
|
|
24304
|
-
|
|
24501
|
+
skills: [
|
|
24502
|
+
buildProfileSoftwareSkill(paths, issueDefaults),
|
|
24503
|
+
buildMapSoftwareSkill(paths, issueDefaults)
|
|
24504
|
+
],
|
|
24505
|
+
subAgents: [buildSoftwareProfileAnalystSubAgent(paths, issueDefaults)],
|
|
24305
24506
|
labels: [
|
|
24306
24507
|
{
|
|
24307
24508
|
name: "type:software-profile",
|
|
@@ -24459,7 +24660,7 @@ var STANDARDS_COMPARE_REFERENCE_FILES = [
|
|
|
24459
24660
|
content: TEMPLATE_COMPARISON_GRID
|
|
24460
24661
|
}
|
|
24461
24662
|
];
|
|
24462
|
-
function buildStandardsResearchAnalystSubAgent(paths) {
|
|
24663
|
+
function buildStandardsResearchAnalystSubAgent(paths, issueDefaults) {
|
|
24463
24664
|
return {
|
|
24464
24665
|
name: "standards-research-analyst",
|
|
24465
24666
|
description: "Authors version-aware interoperability standards research through a 5-phase pipeline (scope \u2192 research \u2192 compare \u2192 extension \u2192 organizations). Researches one standard version per session, synthesizes cross-version comparisons, profiles extensions/profiles/implementation guides, and profiles standards-body organizations. Hands off canonical company and people profiles to the company-profile and people-profile bundles via company:research and people:research issues. One phase per session, tracked by standards:* GitHub issue labels with filesystem-based durability between phases.",
|
|
@@ -24823,12 +25024,23 @@ function buildStandardsResearchAnalystSubAgent(paths) {
|
|
|
24823
25024
|
" *Organizations of Interest* that does not already have a",
|
|
24824
25025
|
" canonical company profile or an open `company:research` issue.",
|
|
24825
25026
|
" The `company-profile` bundle owns the downstream profile; this",
|
|
24826
|
-
" agent only hands off.",
|
|
25027
|
+
" agent only hands off. Each issue must carry:",
|
|
25028
|
+
"",
|
|
25029
|
+
" - `type:company-profile`",
|
|
25030
|
+
" - `company:research`",
|
|
25031
|
+
` - \`priority:${labelsForPhase(issueDefaults, "company:research").priority}\``,
|
|
25032
|
+
` - \`status:${labelsForPhase(issueDefaults, "company:research").status}\``,
|
|
24827
25033
|
"",
|
|
24828
25034
|
"6. **Create `people:research` issues** for every entry in *People of",
|
|
24829
25035
|
" Interest* that does not already have a canonical person profile",
|
|
24830
25036
|
" or an open `people:research` issue. The `people-profile` bundle",
|
|
24831
|
-
" owns the downstream profile; this agent only hands off.",
|
|
25037
|
+
" owns the downstream profile; this agent only hands off. Each",
|
|
25038
|
+
" issue must carry:",
|
|
25039
|
+
"",
|
|
25040
|
+
" - `type:people-profile`",
|
|
25041
|
+
" - `people:research`",
|
|
25042
|
+
` - \`priority:${labelsForPhase(issueDefaults, "people:research").priority}\``,
|
|
25043
|
+
` - \`status:${labelsForPhase(issueDefaults, "people:research").status}\``,
|
|
24832
25044
|
"",
|
|
24833
25045
|
"7. **Verify all handoffs were created** before committing. For each",
|
|
24834
25046
|
" entity in both tables, confirm an existing profile or a fresh",
|
|
@@ -25115,12 +25327,23 @@ function buildStandardsResearchAnalystSubAgent(paths) {
|
|
|
25115
25327
|
" `company:research` issue if no canonical profile exists and no",
|
|
25116
25328
|
" open `company:research` issue is already tracking this",
|
|
25117
25329
|
" organization. The `company-profile` bundle owns the downstream",
|
|
25118
|
-
" profile.",
|
|
25330
|
+
" profile. The issue must carry:",
|
|
25331
|
+
"",
|
|
25332
|
+
" - `type:company-profile`",
|
|
25333
|
+
" - `company:research`",
|
|
25334
|
+
` - \`priority:${labelsForPhase(issueDefaults, "company:research").priority}\``,
|
|
25335
|
+
` - \`status:${labelsForPhase(issueDefaults, "company:research").status}\``,
|
|
25119
25336
|
"",
|
|
25120
25337
|
"6. **Hand off canonical people profiles** by creating one",
|
|
25121
25338
|
" `people:research` issue per leadership entry that does not",
|
|
25122
25339
|
" already have a canonical profile or an open `people:research`",
|
|
25123
25340
|
" issue. The `people-profile` bundle owns the downstream profiles.",
|
|
25341
|
+
" Each issue must carry:",
|
|
25342
|
+
"",
|
|
25343
|
+
" - `type:people-profile`",
|
|
25344
|
+
" - `people:research`",
|
|
25345
|
+
` - \`priority:${labelsForPhase(issueDefaults, "people:research").priority}\``,
|
|
25346
|
+
` - \`status:${labelsForPhase(issueDefaults, "people:research").status}\``,
|
|
25124
25347
|
"",
|
|
25125
25348
|
"7. **Commit and push** the organization page. Close the",
|
|
25126
25349
|
" organizations issue.",
|
|
@@ -25246,7 +25469,7 @@ function buildStandardsResearchAnalystSubAgent(paths) {
|
|
|
25246
25469
|
].join("\n")
|
|
25247
25470
|
};
|
|
25248
25471
|
}
|
|
25249
|
-
function buildScopeStandardsResearchSkill(paths) {
|
|
25472
|
+
function buildScopeStandardsResearchSkill(paths, issueDefaults) {
|
|
25250
25473
|
return {
|
|
25251
25474
|
name: "scope-standards-research",
|
|
25252
25475
|
description: "Kick off the scope phase of an interoperability-standards research campaign. Creates a standards:scope issue for the supplied standard and dispatches Phase 1 of the standards-research-analyst, which writes a query plan and creates downstream standards:research, standards:compare, and standards:organizations issues.",
|
|
@@ -25293,7 +25516,7 @@ function buildScopeStandardsResearchSkill(paths) {
|
|
|
25293
25516
|
"## Steps",
|
|
25294
25517
|
"",
|
|
25295
25518
|
"1. Create a `standards:scope` issue with `type:standards-research`,",
|
|
25296
|
-
|
|
25519
|
+
` \`priority:${labelsForPhase(issueDefaults, "standards:scope").priority}\`, and \`status:${labelsForPhase(issueDefaults, "standards:scope").status}\`. The body must include the`,
|
|
25297
25520
|
" standard slug, the list of target versions (or a request to",
|
|
25298
25521
|
" enumerate), and any known governance bodies.",
|
|
25299
25522
|
"2. Execute Phase 1 (Scope) of the standards-research-analyst agent.",
|
|
@@ -25312,7 +25535,7 @@ function buildScopeStandardsResearchSkill(paths) {
|
|
|
25312
25535
|
].join("\n")
|
|
25313
25536
|
};
|
|
25314
25537
|
}
|
|
25315
|
-
function buildResearchStandardSkill(paths) {
|
|
25538
|
+
function buildResearchStandardSkill(paths, issueDefaults) {
|
|
25316
25539
|
return {
|
|
25317
25540
|
name: "research-standard",
|
|
25318
25541
|
description: "Kick off the research phase for one version of an interoperability standard. Creates a standards:research issue for the supplied standard and version and dispatches Phase 2 of the standards-research-analyst, which populates the version page with status, key changes, resources, adoption, and governance touch-points.",
|
|
@@ -25358,7 +25581,7 @@ function buildResearchStandardSkill(paths) {
|
|
|
25358
25581
|
"## Steps",
|
|
25359
25582
|
"",
|
|
25360
25583
|
"1. Create a `standards:research` issue with",
|
|
25361
|
-
|
|
25584
|
+
` \`type:standards-research\`, \`priority:${labelsForPhase(issueDefaults, "standards:research").priority}\`, and \`status:${labelsForPhase(issueDefaults, "standards:research").status}\`.`,
|
|
25362
25585
|
" The body must include the standard slug and the version slug.",
|
|
25363
25586
|
"2. Execute Phase 2 (Research) of the standards-research-analyst",
|
|
25364
25587
|
" agent. The agent runs 6\u201310 targeted web searches and populates",
|
|
@@ -25377,7 +25600,7 @@ function buildResearchStandardSkill(paths) {
|
|
|
25377
25600
|
].join("\n")
|
|
25378
25601
|
};
|
|
25379
25602
|
}
|
|
25380
|
-
function buildCompareStandardsSkill(paths) {
|
|
25603
|
+
function buildCompareStandardsSkill(paths, issueDefaults) {
|
|
25381
25604
|
return {
|
|
25382
25605
|
name: "compare-standards",
|
|
25383
25606
|
description: "Kick off the compare phase across researched versions of an interoperability standard. Creates a standards:compare issue for the supplied standard and dispatches Phase 3 of the standards-research-analyst, which synthesizes the overview page using the ship-with comparison-grid template.",
|
|
@@ -25430,7 +25653,7 @@ function buildCompareStandardsSkill(paths) {
|
|
|
25430
25653
|
"## Steps",
|
|
25431
25654
|
"",
|
|
25432
25655
|
"1. Create a `standards:compare` issue with",
|
|
25433
|
-
|
|
25656
|
+
` \`type:standards-research\`, \`priority:${labelsForPhase(issueDefaults, "standards:compare").priority}\`, and \`status:${labelsForPhase(issueDefaults, "standards:compare").status}\`.`,
|
|
25434
25657
|
" Body must include the standard slug and the list of version",
|
|
25435
25658
|
" pages under comparison.",
|
|
25436
25659
|
"2. Execute Phase 3 (Compare) of the standards-research-analyst",
|
|
@@ -25447,7 +25670,7 @@ function buildCompareStandardsSkill(paths) {
|
|
|
25447
25670
|
].join("\n")
|
|
25448
25671
|
};
|
|
25449
25672
|
}
|
|
25450
|
-
function buildExtensionStandardSkill(paths) {
|
|
25673
|
+
function buildExtensionStandardSkill(paths, issueDefaults) {
|
|
25451
25674
|
return {
|
|
25452
25675
|
name: "extension-standard",
|
|
25453
25676
|
description: "Kick off the extension phase for one domain entity against an interoperability standard. Creates a standards:extension issue for the supplied standard and domain entity and dispatches Phase 4 of the standards-research-analyst, which analyzes the gap and hands off a Proposed ADR to the requirements pipeline.",
|
|
@@ -25497,7 +25720,7 @@ function buildExtensionStandardSkill(paths) {
|
|
|
25497
25720
|
"## Steps",
|
|
25498
25721
|
"",
|
|
25499
25722
|
"1. Create a `standards:extension` issue with",
|
|
25500
|
-
|
|
25723
|
+
` \`type:standards-research\`, \`priority:${labelsForPhase(issueDefaults, "standards:extension").priority}\`, and \`status:${labelsForPhase(issueDefaults, "standards:extension").status}\`.`,
|
|
25501
25724
|
" The body must include the standard slug, the entity slug, the",
|
|
25502
25725
|
" closest resource, and a link to the source BCM or canvas",
|
|
25503
25726
|
" document.",
|
|
@@ -25517,7 +25740,7 @@ function buildExtensionStandardSkill(paths) {
|
|
|
25517
25740
|
].join("\n")
|
|
25518
25741
|
};
|
|
25519
25742
|
}
|
|
25520
|
-
function buildOrganizationsStandardSkill(paths) {
|
|
25743
|
+
function buildOrganizationsStandardSkill(paths, issueDefaults) {
|
|
25521
25744
|
return {
|
|
25522
25745
|
name: "organizations-standard",
|
|
25523
25746
|
description: "Kick off the organizations phase for one standards-body organization. Creates a standards:organizations issue for the supplied standard and organization and dispatches Phase 5 of the standards-research-analyst, which writes a standards-organization page and hands off canonical company and people profiles to the company-profile and people-profile bundles.",
|
|
@@ -25563,7 +25786,7 @@ function buildOrganizationsStandardSkill(paths) {
|
|
|
25563
25786
|
"## Steps",
|
|
25564
25787
|
"",
|
|
25565
25788
|
"1. Create a `standards:organizations` issue with",
|
|
25566
|
-
|
|
25789
|
+
` \`type:standards-research\`, \`priority:${labelsForPhase(issueDefaults, "standards:organizations").priority}\`, and \`status:${labelsForPhase(issueDefaults, "standards:organizations").status}\`.`,
|
|
25567
25790
|
" Body must include the standard slug, the organization slug, and",
|
|
25568
25791
|
" the organization's governance role.",
|
|
25569
25792
|
"2. Execute Phase 5 (Organizations) of the",
|
|
@@ -25584,7 +25807,7 @@ function buildOrganizationsStandardSkill(paths) {
|
|
|
25584
25807
|
].join("\n")
|
|
25585
25808
|
};
|
|
25586
25809
|
}
|
|
25587
|
-
function buildStandardsResearchBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
25810
|
+
function buildStandardsResearchBundle(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
25588
25811
|
return {
|
|
25589
25812
|
name: "standards-research",
|
|
25590
25813
|
description: "Interoperability-standards research pipeline: scope, research, compare, extension, organizations. 5 phases with standards:* phase labels. Version-aware research, cross-version comparison, extension/profile profiling, and standards-body organization profiling. Hands off canonical profiles to company-profile and people-profile via company:research and people:research issues, extension ADRs to requirements-writer via req:write, and domain-entity mappings to bcm-writer. Enabled by default; domain-neutral; filesystem-durable between phases.",
|
|
@@ -25650,13 +25873,13 @@ function buildStandardsResearchBundle(paths = DEFAULT_AGENT_PATHS) {
|
|
|
25650
25873
|
}
|
|
25651
25874
|
],
|
|
25652
25875
|
skills: [
|
|
25653
|
-
buildScopeStandardsResearchSkill(paths),
|
|
25654
|
-
buildResearchStandardSkill(paths),
|
|
25655
|
-
buildCompareStandardsSkill(paths),
|
|
25656
|
-
buildExtensionStandardSkill(paths),
|
|
25657
|
-
buildOrganizationsStandardSkill(paths)
|
|
25876
|
+
buildScopeStandardsResearchSkill(paths, issueDefaults),
|
|
25877
|
+
buildResearchStandardSkill(paths, issueDefaults),
|
|
25878
|
+
buildCompareStandardsSkill(paths, issueDefaults),
|
|
25879
|
+
buildExtensionStandardSkill(paths, issueDefaults),
|
|
25880
|
+
buildOrganizationsStandardSkill(paths, issueDefaults)
|
|
25658
25881
|
],
|
|
25659
|
-
subAgents: [buildStandardsResearchAnalystSubAgent(paths)],
|
|
25882
|
+
subAgents: [buildStandardsResearchAnalystSubAgent(paths, issueDefaults)],
|
|
25660
25883
|
labels: [
|
|
25661
25884
|
{
|
|
25662
25885
|
name: "type:standards-research",
|
|
@@ -26880,7 +27103,7 @@ function renderPriorityRulesSection(rules) {
|
|
|
26880
27103
|
}
|
|
26881
27104
|
|
|
26882
27105
|
// src/agent/bundles/index.ts
|
|
26883
|
-
function buildBuiltInBundles(paths = DEFAULT_AGENT_PATHS) {
|
|
27106
|
+
function buildBuiltInBundles(paths = DEFAULT_AGENT_PATHS, issueDefaults = DEFAULT_RESOLVED_ISSUE_DEFAULTS) {
|
|
26884
27107
|
return [
|
|
26885
27108
|
buildBaseBundle(paths),
|
|
26886
27109
|
upstreamConfigulatorDocsBundle,
|
|
@@ -26897,20 +27120,20 @@ function buildBuiltInBundles(paths = DEFAULT_AGENT_PATHS) {
|
|
|
26897
27120
|
agendaBundle,
|
|
26898
27121
|
orchestratorBundle,
|
|
26899
27122
|
prReviewBundle,
|
|
26900
|
-
buildRequirementsAnalystBundle(paths),
|
|
26901
|
-
buildRequirementsWriterBundle(paths),
|
|
26902
|
-
buildRequirementsReviewerBundle(paths),
|
|
26903
|
-
buildResearchPipelineBundle(paths),
|
|
26904
|
-
buildCompanyProfileBundle(paths),
|
|
26905
|
-
buildCustomerProfileBundle(paths),
|
|
26906
|
-
buildPeopleProfileBundle(paths),
|
|
26907
|
-
buildSoftwareProfileBundle(paths),
|
|
26908
|
-
buildIndustryDiscoveryBundle(paths),
|
|
26909
|
-
buildBusinessModelsBundle(paths),
|
|
26910
|
-
buildBcmWriterBundle(paths),
|
|
26911
|
-
buildStandardsResearchBundle(paths),
|
|
26912
|
-
buildRegulatoryResearchBundle(paths),
|
|
26913
|
-
buildMaintenanceAuditBundle(paths),
|
|
27123
|
+
buildRequirementsAnalystBundle(paths, issueDefaults),
|
|
27124
|
+
buildRequirementsWriterBundle(paths, issueDefaults),
|
|
27125
|
+
buildRequirementsReviewerBundle(paths, issueDefaults),
|
|
27126
|
+
buildResearchPipelineBundle(paths, issueDefaults),
|
|
27127
|
+
buildCompanyProfileBundle(paths, issueDefaults),
|
|
27128
|
+
buildCustomerProfileBundle(paths, issueDefaults),
|
|
27129
|
+
buildPeopleProfileBundle(paths, issueDefaults),
|
|
27130
|
+
buildSoftwareProfileBundle(paths, issueDefaults),
|
|
27131
|
+
buildIndustryDiscoveryBundle(paths, issueDefaults),
|
|
27132
|
+
buildBusinessModelsBundle(paths, issueDefaults),
|
|
27133
|
+
buildBcmWriterBundle(paths, issueDefaults),
|
|
27134
|
+
buildStandardsResearchBundle(paths, issueDefaults),
|
|
27135
|
+
buildRegulatoryResearchBundle(paths, issueDefaults),
|
|
27136
|
+
buildMaintenanceAuditBundle(paths, issueDefaults),
|
|
26914
27137
|
buildDocsSyncBundle(paths)
|
|
26915
27138
|
];
|
|
26916
27139
|
}
|
|
@@ -26948,6 +27171,152 @@ function prefix(rel, entry) {
|
|
|
26948
27171
|
return path.posix.join(rel, entry);
|
|
26949
27172
|
}
|
|
26950
27173
|
|
|
27174
|
+
// src/agent/renderers/cursor-renderer.ts
|
|
27175
|
+
import { JsonFile as JsonFile2 } from "projen";
|
|
27176
|
+
import { TextFile as TextFile2 } from "projen/lib/textfile";
|
|
27177
|
+
var GENERATED_MARKER = "# ~~ Generated by @codedrifters/configulator. Edits welcome \u2014 please contribute improvements back. ~~";
|
|
27178
|
+
var CursorRenderer = class _CursorRenderer {
|
|
27179
|
+
/**
|
|
27180
|
+
* Render all Cursor configuration files.
|
|
27181
|
+
*/
|
|
27182
|
+
static render(component, rules, skills, subAgents, mcpServers, settings) {
|
|
27183
|
+
_CursorRenderer.renderRules(component, rules);
|
|
27184
|
+
_CursorRenderer.renderSkills(component, skills);
|
|
27185
|
+
_CursorRenderer.renderSubAgents(component, subAgents);
|
|
27186
|
+
_CursorRenderer.renderMcpServers(component, mcpServers);
|
|
27187
|
+
_CursorRenderer.renderHooks(component, settings);
|
|
27188
|
+
_CursorRenderer.renderIgnoreFiles(component, settings);
|
|
27189
|
+
}
|
|
27190
|
+
static renderRules(component, rules) {
|
|
27191
|
+
for (const rule of rules) {
|
|
27192
|
+
if (rule.platforms?.cursor?.exclude) continue;
|
|
27193
|
+
const lines = [];
|
|
27194
|
+
const description = rule.platforms?.cursor?.description ?? rule.description;
|
|
27195
|
+
const isAlways = rule.scope === AGENT_RULE_SCOPE.ALWAYS;
|
|
27196
|
+
lines.push("---");
|
|
27197
|
+
lines.push(`description: "${description}"`);
|
|
27198
|
+
lines.push(`alwaysApply: ${isAlways}`);
|
|
27199
|
+
if (!isAlways && rule.filePatterns && rule.filePatterns.length > 0) {
|
|
27200
|
+
lines.push(`path: ${JSON.stringify([...rule.filePatterns])}`);
|
|
27201
|
+
}
|
|
27202
|
+
lines.push("---");
|
|
27203
|
+
lines.push("");
|
|
27204
|
+
lines.push(...rule.content.split("\n"));
|
|
27205
|
+
new TextFile2(component, `.cursor/rules/${rule.name}.mdc`, { lines });
|
|
27206
|
+
}
|
|
27207
|
+
}
|
|
27208
|
+
static renderSkills(component, skills) {
|
|
27209
|
+
for (const skill of skills) {
|
|
27210
|
+
if (skill.platforms?.cursor?.exclude) continue;
|
|
27211
|
+
const lines = [];
|
|
27212
|
+
lines.push("---");
|
|
27213
|
+
lines.push(`name: "${skill.name}"`);
|
|
27214
|
+
lines.push(`description: "${skill.description}"`);
|
|
27215
|
+
if (skill.disableModelInvocation) {
|
|
27216
|
+
lines.push(`disable-model-invocation: true`);
|
|
27217
|
+
}
|
|
27218
|
+
if (skill.userInvocable === false) {
|
|
27219
|
+
lines.push(`user-invocable: false`);
|
|
27220
|
+
}
|
|
27221
|
+
if (skill.context) {
|
|
27222
|
+
lines.push(`context: "${skill.context}"`);
|
|
27223
|
+
}
|
|
27224
|
+
if (skill.agent) {
|
|
27225
|
+
lines.push(`agent: "${skill.agent}"`);
|
|
27226
|
+
}
|
|
27227
|
+
if (skill.shell) {
|
|
27228
|
+
lines.push(`shell: "${skill.shell}"`);
|
|
27229
|
+
}
|
|
27230
|
+
if (skill.allowedTools && skill.allowedTools.length > 0) {
|
|
27231
|
+
lines.push(`allowed-tools:`);
|
|
27232
|
+
for (const tool of skill.allowedTools) {
|
|
27233
|
+
lines.push(` - "${tool}"`);
|
|
27234
|
+
}
|
|
27235
|
+
}
|
|
27236
|
+
lines.push("---");
|
|
27237
|
+
lines.push("");
|
|
27238
|
+
lines.push(...skill.instructions.split("\n"));
|
|
27239
|
+
new TextFile2(component, `.cursor/skills/${skill.name}/SKILL.md`, {
|
|
27240
|
+
lines
|
|
27241
|
+
});
|
|
27242
|
+
if (skill.referenceFiles && skill.referenceFiles.length > 0) {
|
|
27243
|
+
for (const file of skill.referenceFiles) {
|
|
27244
|
+
new TextFile2(component, `.cursor/skills/${skill.name}/${file.path}`, {
|
|
27245
|
+
lines: file.content.split("\n")
|
|
27246
|
+
});
|
|
27247
|
+
}
|
|
27248
|
+
}
|
|
27249
|
+
}
|
|
27250
|
+
}
|
|
27251
|
+
static renderSubAgents(component, subAgents) {
|
|
27252
|
+
for (const agent of subAgents) {
|
|
27253
|
+
if (agent.platforms?.cursor?.exclude) continue;
|
|
27254
|
+
const lines = [];
|
|
27255
|
+
lines.push("---");
|
|
27256
|
+
lines.push(`name: ${agent.name}`);
|
|
27257
|
+
lines.push(`description: >-`);
|
|
27258
|
+
lines.push(` ${agent.description}`);
|
|
27259
|
+
if (agent.platforms?.cursor?.readonly) {
|
|
27260
|
+
lines.push(`readonly: true`);
|
|
27261
|
+
}
|
|
27262
|
+
if (agent.platforms?.cursor?.isBackground) {
|
|
27263
|
+
lines.push(`is_background: true`);
|
|
27264
|
+
}
|
|
27265
|
+
lines.push("---");
|
|
27266
|
+
lines.push("");
|
|
27267
|
+
lines.push(...agent.prompt.split("\n"));
|
|
27268
|
+
new TextFile2(component, `.cursor/agents/${agent.name}.md`, { lines });
|
|
27269
|
+
}
|
|
27270
|
+
}
|
|
27271
|
+
static renderMcpServers(component, mcpServers) {
|
|
27272
|
+
const serverNames = Object.keys(mcpServers);
|
|
27273
|
+
if (serverNames.length === 0) return;
|
|
27274
|
+
const obj = { mcpServers: {} };
|
|
27275
|
+
const servers = obj.mcpServers;
|
|
27276
|
+
for (const [name, config] of Object.entries(mcpServers)) {
|
|
27277
|
+
const server = {};
|
|
27278
|
+
if (config.transport) server.transport = config.transport;
|
|
27279
|
+
if (config.command) server.command = config.command;
|
|
27280
|
+
if (config.args) server.args = [...config.args];
|
|
27281
|
+
if (config.url) server.url = config.url;
|
|
27282
|
+
if (config.headers && Object.keys(config.headers).length > 0) {
|
|
27283
|
+
server.headers = { ...config.headers };
|
|
27284
|
+
}
|
|
27285
|
+
if (config.env) server.env = { ...config.env };
|
|
27286
|
+
servers[name] = server;
|
|
27287
|
+
}
|
|
27288
|
+
new JsonFile2(component, ".cursor/mcp.json", { obj });
|
|
27289
|
+
}
|
|
27290
|
+
static renderHooks(component, settings) {
|
|
27291
|
+
if (!settings?.hooks) return;
|
|
27292
|
+
const hooks = {};
|
|
27293
|
+
const hookEntries = settings.hooks;
|
|
27294
|
+
for (const [event, actions] of Object.entries(hookEntries)) {
|
|
27295
|
+
if (actions && actions.length > 0) {
|
|
27296
|
+
hooks[event] = actions.map((h) => ({
|
|
27297
|
+
command: h.command
|
|
27298
|
+
}));
|
|
27299
|
+
}
|
|
27300
|
+
}
|
|
27301
|
+
if (Object.keys(hooks).length === 0) return;
|
|
27302
|
+
new JsonFile2(component, ".cursor/hooks.json", {
|
|
27303
|
+
obj: { version: 1, hooks }
|
|
27304
|
+
});
|
|
27305
|
+
}
|
|
27306
|
+
static renderIgnoreFiles(component, settings) {
|
|
27307
|
+
if (settings?.ignorePatterns && settings.ignorePatterns.length > 0) {
|
|
27308
|
+
new TextFile2(component, ".cursorignore", {
|
|
27309
|
+
lines: [GENERATED_MARKER, "", ...settings.ignorePatterns]
|
|
27310
|
+
});
|
|
27311
|
+
}
|
|
27312
|
+
if (settings?.indexingIgnorePatterns && settings.indexingIgnorePatterns.length > 0) {
|
|
27313
|
+
new TextFile2(component, ".cursorindexingignore", {
|
|
27314
|
+
lines: [GENERATED_MARKER, "", ...settings.indexingIgnorePatterns]
|
|
27315
|
+
});
|
|
27316
|
+
}
|
|
27317
|
+
}
|
|
27318
|
+
};
|
|
27319
|
+
|
|
26951
27320
|
// src/agent/template-resolver.ts
|
|
26952
27321
|
var FALLBACKS = {
|
|
26953
27322
|
"repository.owner": "<owner>",
|
|
@@ -27003,9 +27372,9 @@ function resolveTemplateVariables(template, metadata) {
|
|
|
27003
27372
|
}
|
|
27004
27373
|
|
|
27005
27374
|
// src/agent/renderers/claude-renderer.ts
|
|
27006
|
-
import { JsonFile as
|
|
27007
|
-
import { TextFile as
|
|
27008
|
-
var
|
|
27375
|
+
import { JsonFile as JsonFile3 } from "projen";
|
|
27376
|
+
import { TextFile as TextFile3 } from "projen/lib/textfile";
|
|
27377
|
+
var GENERATED_MARKER2 = "<!-- ~~ Generated by @codedrifters/configulator. Edits welcome \u2014 please contribute improvements back. ~~ -->";
|
|
27009
27378
|
var ClaudeRenderer = class _ClaudeRenderer {
|
|
27010
27379
|
/**
|
|
27011
27380
|
* Render all Claude Code configuration files.
|
|
@@ -27027,12 +27396,12 @@ var ClaudeRenderer = class _ClaudeRenderer {
|
|
|
27027
27396
|
return target === CLAUDE_RULE_TARGET.CLAUDE_MD;
|
|
27028
27397
|
});
|
|
27029
27398
|
if (claudeMdRules.length === 0) return;
|
|
27030
|
-
const lines = [
|
|
27399
|
+
const lines = [GENERATED_MARKER2, ""];
|
|
27031
27400
|
for (let i = 0; i < claudeMdRules.length; i++) {
|
|
27032
27401
|
if (i > 0) lines.push("", "---", "");
|
|
27033
27402
|
lines.push(...claudeMdRules[i].content.split("\n"));
|
|
27034
27403
|
}
|
|
27035
|
-
new
|
|
27404
|
+
new TextFile3(component, "CLAUDE.md", { lines });
|
|
27036
27405
|
}
|
|
27037
27406
|
static renderScopedRules(component, rules) {
|
|
27038
27407
|
const scopedRules = rules.filter((r) => {
|
|
@@ -27052,7 +27421,7 @@ var ClaudeRenderer = class _ClaudeRenderer {
|
|
|
27052
27421
|
lines.push("");
|
|
27053
27422
|
}
|
|
27054
27423
|
lines.push(...rule.content.split("\n"));
|
|
27055
|
-
new
|
|
27424
|
+
new TextFile3(component, `.claude/rules/${rule.name}.md`, { lines });
|
|
27056
27425
|
}
|
|
27057
27426
|
}
|
|
27058
27427
|
static renderSettings(component, mcpServers, settings) {
|
|
@@ -27177,7 +27546,7 @@ var ClaudeRenderer = class _ClaudeRenderer {
|
|
|
27177
27546
|
hasContent = true;
|
|
27178
27547
|
}
|
|
27179
27548
|
if (!hasContent) return;
|
|
27180
|
-
new
|
|
27549
|
+
new JsonFile3(component, ".claude/settings.json", { obj });
|
|
27181
27550
|
}
|
|
27182
27551
|
static buildSandboxObj(sandbox) {
|
|
27183
27552
|
const obj = {};
|
|
@@ -27264,12 +27633,12 @@ var ClaudeRenderer = class _ClaudeRenderer {
|
|
|
27264
27633
|
lines.push("---");
|
|
27265
27634
|
lines.push("");
|
|
27266
27635
|
lines.push(...skill.instructions.split("\n"));
|
|
27267
|
-
new
|
|
27636
|
+
new TextFile3(component, `.claude/skills/${skill.name}/SKILL.md`, {
|
|
27268
27637
|
lines
|
|
27269
27638
|
});
|
|
27270
27639
|
if (skill.referenceFiles && skill.referenceFiles.length > 0) {
|
|
27271
27640
|
for (const file of skill.referenceFiles) {
|
|
27272
|
-
new
|
|
27641
|
+
new TextFile3(component, `.claude/skills/${skill.name}/${file.path}`, {
|
|
27273
27642
|
lines: file.content.split("\n")
|
|
27274
27643
|
});
|
|
27275
27644
|
}
|
|
@@ -27327,7 +27696,7 @@ var ClaudeRenderer = class _ClaudeRenderer {
|
|
|
27327
27696
|
lines.push("---");
|
|
27328
27697
|
lines.push("");
|
|
27329
27698
|
lines.push(...agent.prompt.split("\n"));
|
|
27330
|
-
new
|
|
27699
|
+
new TextFile3(component, `.claude/agents/${agent.name}.md`, { lines });
|
|
27331
27700
|
}
|
|
27332
27701
|
}
|
|
27333
27702
|
static buildMcpServerObj(config) {
|
|
@@ -27344,7 +27713,7 @@ var ClaudeRenderer = class _ClaudeRenderer {
|
|
|
27344
27713
|
}
|
|
27345
27714
|
static renderProcedures(component, procedures) {
|
|
27346
27715
|
for (const proc of procedures) {
|
|
27347
|
-
new
|
|
27716
|
+
new TextFile3(component, `.claude/procedures/${proc.name}`, {
|
|
27348
27717
|
lines: proc.content.split("\n"),
|
|
27349
27718
|
executable: true
|
|
27350
27719
|
});
|
|
@@ -27371,152 +27740,6 @@ var CopilotRenderer = class {
|
|
|
27371
27740
|
}
|
|
27372
27741
|
};
|
|
27373
27742
|
|
|
27374
|
-
// src/agent/renderers/cursor-renderer.ts
|
|
27375
|
-
import { JsonFile as JsonFile3 } from "projen";
|
|
27376
|
-
import { TextFile as TextFile3 } from "projen/lib/textfile";
|
|
27377
|
-
var GENERATED_MARKER2 = "# ~~ Generated by @codedrifters/configulator. Edits welcome \u2014 please contribute improvements back. ~~";
|
|
27378
|
-
var CursorRenderer = class _CursorRenderer {
|
|
27379
|
-
/**
|
|
27380
|
-
* Render all Cursor configuration files.
|
|
27381
|
-
*/
|
|
27382
|
-
static render(component, rules, skills, subAgents, mcpServers, settings) {
|
|
27383
|
-
_CursorRenderer.renderRules(component, rules);
|
|
27384
|
-
_CursorRenderer.renderSkills(component, skills);
|
|
27385
|
-
_CursorRenderer.renderSubAgents(component, subAgents);
|
|
27386
|
-
_CursorRenderer.renderMcpServers(component, mcpServers);
|
|
27387
|
-
_CursorRenderer.renderHooks(component, settings);
|
|
27388
|
-
_CursorRenderer.renderIgnoreFiles(component, settings);
|
|
27389
|
-
}
|
|
27390
|
-
static renderRules(component, rules) {
|
|
27391
|
-
for (const rule of rules) {
|
|
27392
|
-
if (rule.platforms?.cursor?.exclude) continue;
|
|
27393
|
-
const lines = [];
|
|
27394
|
-
const description = rule.platforms?.cursor?.description ?? rule.description;
|
|
27395
|
-
const isAlways = rule.scope === AGENT_RULE_SCOPE.ALWAYS;
|
|
27396
|
-
lines.push("---");
|
|
27397
|
-
lines.push(`description: "${description}"`);
|
|
27398
|
-
lines.push(`alwaysApply: ${isAlways}`);
|
|
27399
|
-
if (!isAlways && rule.filePatterns && rule.filePatterns.length > 0) {
|
|
27400
|
-
lines.push(`path: ${JSON.stringify([...rule.filePatterns])}`);
|
|
27401
|
-
}
|
|
27402
|
-
lines.push("---");
|
|
27403
|
-
lines.push("");
|
|
27404
|
-
lines.push(...rule.content.split("\n"));
|
|
27405
|
-
new TextFile3(component, `.cursor/rules/${rule.name}.mdc`, { lines });
|
|
27406
|
-
}
|
|
27407
|
-
}
|
|
27408
|
-
static renderSkills(component, skills) {
|
|
27409
|
-
for (const skill of skills) {
|
|
27410
|
-
if (skill.platforms?.cursor?.exclude) continue;
|
|
27411
|
-
const lines = [];
|
|
27412
|
-
lines.push("---");
|
|
27413
|
-
lines.push(`name: "${skill.name}"`);
|
|
27414
|
-
lines.push(`description: "${skill.description}"`);
|
|
27415
|
-
if (skill.disableModelInvocation) {
|
|
27416
|
-
lines.push(`disable-model-invocation: true`);
|
|
27417
|
-
}
|
|
27418
|
-
if (skill.userInvocable === false) {
|
|
27419
|
-
lines.push(`user-invocable: false`);
|
|
27420
|
-
}
|
|
27421
|
-
if (skill.context) {
|
|
27422
|
-
lines.push(`context: "${skill.context}"`);
|
|
27423
|
-
}
|
|
27424
|
-
if (skill.agent) {
|
|
27425
|
-
lines.push(`agent: "${skill.agent}"`);
|
|
27426
|
-
}
|
|
27427
|
-
if (skill.shell) {
|
|
27428
|
-
lines.push(`shell: "${skill.shell}"`);
|
|
27429
|
-
}
|
|
27430
|
-
if (skill.allowedTools && skill.allowedTools.length > 0) {
|
|
27431
|
-
lines.push(`allowed-tools:`);
|
|
27432
|
-
for (const tool of skill.allowedTools) {
|
|
27433
|
-
lines.push(` - "${tool}"`);
|
|
27434
|
-
}
|
|
27435
|
-
}
|
|
27436
|
-
lines.push("---");
|
|
27437
|
-
lines.push("");
|
|
27438
|
-
lines.push(...skill.instructions.split("\n"));
|
|
27439
|
-
new TextFile3(component, `.cursor/skills/${skill.name}/SKILL.md`, {
|
|
27440
|
-
lines
|
|
27441
|
-
});
|
|
27442
|
-
if (skill.referenceFiles && skill.referenceFiles.length > 0) {
|
|
27443
|
-
for (const file of skill.referenceFiles) {
|
|
27444
|
-
new TextFile3(component, `.cursor/skills/${skill.name}/${file.path}`, {
|
|
27445
|
-
lines: file.content.split("\n")
|
|
27446
|
-
});
|
|
27447
|
-
}
|
|
27448
|
-
}
|
|
27449
|
-
}
|
|
27450
|
-
}
|
|
27451
|
-
static renderSubAgents(component, subAgents) {
|
|
27452
|
-
for (const agent of subAgents) {
|
|
27453
|
-
if (agent.platforms?.cursor?.exclude) continue;
|
|
27454
|
-
const lines = [];
|
|
27455
|
-
lines.push("---");
|
|
27456
|
-
lines.push(`name: ${agent.name}`);
|
|
27457
|
-
lines.push(`description: >-`);
|
|
27458
|
-
lines.push(` ${agent.description}`);
|
|
27459
|
-
if (agent.platforms?.cursor?.readonly) {
|
|
27460
|
-
lines.push(`readonly: true`);
|
|
27461
|
-
}
|
|
27462
|
-
if (agent.platforms?.cursor?.isBackground) {
|
|
27463
|
-
lines.push(`is_background: true`);
|
|
27464
|
-
}
|
|
27465
|
-
lines.push("---");
|
|
27466
|
-
lines.push("");
|
|
27467
|
-
lines.push(...agent.prompt.split("\n"));
|
|
27468
|
-
new TextFile3(component, `.cursor/agents/${agent.name}.md`, { lines });
|
|
27469
|
-
}
|
|
27470
|
-
}
|
|
27471
|
-
static renderMcpServers(component, mcpServers) {
|
|
27472
|
-
const serverNames = Object.keys(mcpServers);
|
|
27473
|
-
if (serverNames.length === 0) return;
|
|
27474
|
-
const obj = { mcpServers: {} };
|
|
27475
|
-
const servers = obj.mcpServers;
|
|
27476
|
-
for (const [name, config] of Object.entries(mcpServers)) {
|
|
27477
|
-
const server = {};
|
|
27478
|
-
if (config.transport) server.transport = config.transport;
|
|
27479
|
-
if (config.command) server.command = config.command;
|
|
27480
|
-
if (config.args) server.args = [...config.args];
|
|
27481
|
-
if (config.url) server.url = config.url;
|
|
27482
|
-
if (config.headers && Object.keys(config.headers).length > 0) {
|
|
27483
|
-
server.headers = { ...config.headers };
|
|
27484
|
-
}
|
|
27485
|
-
if (config.env) server.env = { ...config.env };
|
|
27486
|
-
servers[name] = server;
|
|
27487
|
-
}
|
|
27488
|
-
new JsonFile3(component, ".cursor/mcp.json", { obj });
|
|
27489
|
-
}
|
|
27490
|
-
static renderHooks(component, settings) {
|
|
27491
|
-
if (!settings?.hooks) return;
|
|
27492
|
-
const hooks = {};
|
|
27493
|
-
const hookEntries = settings.hooks;
|
|
27494
|
-
for (const [event, actions] of Object.entries(hookEntries)) {
|
|
27495
|
-
if (actions && actions.length > 0) {
|
|
27496
|
-
hooks[event] = actions.map((h) => ({
|
|
27497
|
-
command: h.command
|
|
27498
|
-
}));
|
|
27499
|
-
}
|
|
27500
|
-
}
|
|
27501
|
-
if (Object.keys(hooks).length === 0) return;
|
|
27502
|
-
new JsonFile3(component, ".cursor/hooks.json", {
|
|
27503
|
-
obj: { version: 1, hooks }
|
|
27504
|
-
});
|
|
27505
|
-
}
|
|
27506
|
-
static renderIgnoreFiles(component, settings) {
|
|
27507
|
-
if (settings?.ignorePatterns && settings.ignorePatterns.length > 0) {
|
|
27508
|
-
new TextFile3(component, ".cursorignore", {
|
|
27509
|
-
lines: [GENERATED_MARKER2, "", ...settings.ignorePatterns]
|
|
27510
|
-
});
|
|
27511
|
-
}
|
|
27512
|
-
if (settings?.indexingIgnorePatterns && settings.indexingIgnorePatterns.length > 0) {
|
|
27513
|
-
new TextFile3(component, ".cursorindexingignore", {
|
|
27514
|
-
lines: [GENERATED_MARKER2, "", ...settings.indexingIgnorePatterns]
|
|
27515
|
-
});
|
|
27516
|
-
}
|
|
27517
|
-
}
|
|
27518
|
-
};
|
|
27519
|
-
|
|
27520
27743
|
// src/agent/agent-config.ts
|
|
27521
27744
|
var DEFAULT_CLAUDE_ALLOW = [
|
|
27522
27745
|
// ── Git ──────────────────────────────────────────────────────────────
|
|
@@ -27742,7 +27965,10 @@ var AgentConfig = class _AgentConfig extends Component8 {
|
|
|
27742
27965
|
*/
|
|
27743
27966
|
get pathAwareBundles() {
|
|
27744
27967
|
if (!this.cachedBundles) {
|
|
27745
|
-
this.cachedBundles = buildBuiltInBundles(
|
|
27968
|
+
this.cachedBundles = buildBuiltInBundles(
|
|
27969
|
+
this.resolvedPaths,
|
|
27970
|
+
resolveIssueDefaults(this.options.issueDefaults)
|
|
27971
|
+
);
|
|
27746
27972
|
}
|
|
27747
27973
|
return this.cachedBundles;
|
|
27748
27974
|
}
|
|
@@ -27788,6 +28014,7 @@ var AgentConfig = class _AgentConfig extends Component8 {
|
|
|
27788
28014
|
this.project.gitignore.addPatterns(`/${resolvedRunRatio.stateFilePath}`);
|
|
27789
28015
|
}
|
|
27790
28016
|
validateUnblockDependentsConfig(this.options.unblockDependents);
|
|
28017
|
+
validateIssueDefaultsConfig(this.options.issueDefaults);
|
|
27791
28018
|
const resolvedProgressFiles = validateProgressFilesConfig(
|
|
27792
28019
|
this.options.progressFiles
|
|
27793
28020
|
);
|
|
@@ -32675,6 +32902,8 @@ export {
|
|
|
32675
32902
|
DEFAULT_DISPATCH_MODEL,
|
|
32676
32903
|
DEFAULT_DISPATCH_TO_HOUSEKEEPING_RATIO,
|
|
32677
32904
|
DEFAULT_HOUSEKEEPING_MODEL,
|
|
32905
|
+
DEFAULT_ISSUE_PRIORITY,
|
|
32906
|
+
DEFAULT_ISSUE_STATUS,
|
|
32678
32907
|
DEFAULT_ISSUE_TEMPLATES_BUNDLE_PATH_PATTERNS,
|
|
32679
32908
|
DEFAULT_ISSUE_TEMPLATES_EMIT_CHECKER,
|
|
32680
32909
|
DEFAULT_ISSUE_TEMPLATES_EMIT_STARTER,
|
|
@@ -32691,6 +32920,7 @@ export {
|
|
|
32691
32920
|
DEFAULT_PROGRESS_FILES_STALE_AFTER_HOURS,
|
|
32692
32921
|
DEFAULT_PROGRESS_FILES_STATE_DIR,
|
|
32693
32922
|
DEFAULT_REQUIRE_PRODUCT_CONTEXT,
|
|
32923
|
+
DEFAULT_RESOLVED_ISSUE_DEFAULTS,
|
|
32694
32924
|
DEFAULT_SAMPLE_COMPILER_OPTIONS,
|
|
32695
32925
|
DEFAULT_SCHEDULED_TASKS_ROOT,
|
|
32696
32926
|
DEFAULT_SCHEDULED_TASK_ENTRIES,
|
|
@@ -32742,6 +32972,8 @@ export {
|
|
|
32742
32972
|
TypeScriptConfig,
|
|
32743
32973
|
TypeScriptProject,
|
|
32744
32974
|
UNKNOWN_TYPE_FALLBACK_TIER,
|
|
32975
|
+
VALID_PRIORITY_VALUES,
|
|
32976
|
+
VALID_STATUS_VALUES,
|
|
32745
32977
|
VERSION,
|
|
32746
32978
|
VERSION_KEYS_SKIP,
|
|
32747
32979
|
VERSION_NPM_PACKAGES,
|
|
@@ -32800,6 +33032,7 @@ export {
|
|
|
32800
33032
|
githubWorkflowBundle,
|
|
32801
33033
|
industryDiscoveryBundle,
|
|
32802
33034
|
jestBundle,
|
|
33035
|
+
labelsForPhase,
|
|
32803
33036
|
maintenanceAuditBundle,
|
|
32804
33037
|
meetingAnalysisBundle,
|
|
32805
33038
|
orchestratorBundle,
|
|
@@ -32853,6 +33086,7 @@ export {
|
|
|
32853
33086
|
resolveAgentTiers,
|
|
32854
33087
|
resolveAstroProjectOutdir,
|
|
32855
33088
|
resolveAwsCdkProjectOutdir,
|
|
33089
|
+
resolveIssueDefaults,
|
|
32856
33090
|
resolveIssueTemplates,
|
|
32857
33091
|
resolveModelAlias,
|
|
32858
33092
|
resolveOrchestratorAssets,
|
|
@@ -32876,6 +33110,7 @@ export {
|
|
|
32876
33110
|
typescriptBundle,
|
|
32877
33111
|
upstreamConfigulatorDocsBundle,
|
|
32878
33112
|
validateAgentTierConfig,
|
|
33113
|
+
validateIssueDefaultsConfig,
|
|
32879
33114
|
validateIssueTemplatesConfig,
|
|
32880
33115
|
validateMonorepoLayout,
|
|
32881
33116
|
validateProgressFilesConfig,
|