@rasensio/aidlc-content 1.35.0 → 1.36.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +1 -0
- package/dist/index.js.map +1 -1
- package/dist/rules.d.ts +14 -0
- package/dist/rules.d.ts.map +1 -0
- package/dist/rules.js +32 -0
- package/dist/rules.js.map +1 -0
- package/dist/types.d.ts +10 -0
- package/dist/types.d.ts.map +1 -1
- package/package.json +1 -1
- package/resources/rules/always-read.md +14 -0
- package/resources/rules/constitution.md +7 -0
- package/resources/rules/context.md +39 -0
- package/resources/rules/creating-an-instance.md +37 -0
- package/resources/rules/lifecycle-or-skill.md +37 -0
- package/resources/rules/question-protocol.md +41 -0
- package/skills/00-overview.md +6 -163
- package/skills/01-getting-started.md +2 -2
- package/skills/03-entry-point.md +2 -2
- package/skills/04-roadmap.md +2 -2
- package/skills/05-constitution.md +1 -1
- package/skills/10-ideation.md +2 -2
- package/skills/20-requirements.md +4 -4
- package/skills/30-design.md +3 -3
- package/skills/40-implementation.md +3 -3
- package/skills/50-testing.md +2 -2
- package/skills/60-deployment.md +2 -2
- package/skills/70-maintenance.md +2 -2
- package/skills/80-review.md +1 -1
- package/skills/81-continue.md +1 -1
- package/skills/83-add-skill.md +1 -1
- package/skills/90-retrospective.md +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -4,6 +4,7 @@ export { loadGuidance } from './guidance.js';
|
|
|
4
4
|
export { loadGlossary, getGlossaryTerm } from './glossary.js';
|
|
5
5
|
export { loadCapabilities, getCapabilityMap } from './capabilities.js';
|
|
6
6
|
export { loadPhases, getPhase } from './phases.js';
|
|
7
|
+
export { loadRules } from './rules.js';
|
|
7
8
|
export { loadTutorials, getTutorial, getSeries, parseTutorialSource } from './tutorials.js';
|
|
8
|
-
export type { Skill, WorkflowTemplate, GuidanceLayer, GlossaryTerm, CapabilityMap, QuestionRendering, PhaseDefinition, CodeSample, ContentReference, TutorialStep, Tutorial, WidgetKind, WidgetReference } from './types.js';
|
|
9
|
+
export type { Skill, WorkflowTemplate, GuidanceLayer, GlossaryTerm, CapabilityMap, QuestionRendering, PhaseDefinition, Rule, CodeSample, ContentReference, TutorialStep, Tutorial, WidgetKind, WidgetReference } from './types.js';
|
|
9
10
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC5D,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAC9D,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AACvE,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,SAAS,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAC5F,YAAY,EAAE,KAAK,EAAE,gBAAgB,EAAE,aAAa,EAAE,YAAY,EAAE,aAAa,EAAE,iBAAiB,EAAE,eAAe,EAAE,UAAU,EAAE,gBAAgB,EAAE,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC5D,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAC9D,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AACvE,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACvC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,SAAS,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC;AAC5F,YAAY,EAAE,KAAK,EAAE,gBAAgB,EAAE,aAAa,EAAE,YAAY,EAAE,aAAa,EAAE,iBAAiB,EAAE,eAAe,EAAE,IAAI,EAAE,UAAU,EAAE,gBAAgB,EAAE,YAAY,EAAE,QAAQ,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,YAAY,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -4,5 +4,6 @@ export { loadGuidance } from './guidance.js';
|
|
|
4
4
|
export { loadGlossary, getGlossaryTerm } from './glossary.js';
|
|
5
5
|
export { loadCapabilities, getCapabilityMap } from './capabilities.js';
|
|
6
6
|
export { loadPhases, getPhase } from './phases.js';
|
|
7
|
+
export { loadRules } from './rules.js';
|
|
7
8
|
export { loadTutorials, getTutorial, getSeries, parseTutorialSource } from './tutorials.js';
|
|
8
9
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC5D,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAC9D,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AACvE,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,SAAS,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC5D,OAAO,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC7C,OAAO,EAAE,YAAY,EAAE,eAAe,EAAE,MAAM,eAAe,CAAC;AAC9D,OAAO,EAAE,gBAAgB,EAAE,gBAAgB,EAAE,MAAM,mBAAmB,CAAC;AACvE,OAAO,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AACnD,OAAO,EAAE,SAAS,EAAE,MAAM,YAAY,CAAC;AACvC,OAAO,EAAE,aAAa,EAAE,WAAW,EAAE,SAAS,EAAE,mBAAmB,EAAE,MAAM,gBAAgB,CAAC"}
|
package/dist/rules.d.ts
ADDED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import type { Rule } from './types.js';
|
|
2
|
+
/**
|
|
3
|
+
* Load every rule the overview skill points at instead of carrying.
|
|
4
|
+
*
|
|
5
|
+
* Each rule is stated once, in its own file, so a skill that cross-references
|
|
6
|
+
* one rule costs the reader that rule and not the whole overview. Both
|
|
7
|
+
* consumers call this: the CLI emits the files into `.aidlc/resources/rules/`,
|
|
8
|
+
* and the website renders them under the overview's docs page. One source, two
|
|
9
|
+
* consumers, no copy.
|
|
10
|
+
*
|
|
11
|
+
* @returns Rules sorted by id.
|
|
12
|
+
*/
|
|
13
|
+
export declare function loadRules(): Rule[];
|
|
14
|
+
//# sourceMappingURL=rules.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rules.d.ts","sourceRoot":"","sources":["../src/rules.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAYvC;;;;;;;;;;GAUG;AACH,wBAAgB,SAAS,IAAI,IAAI,EAAE,CAOlC"}
|
package/dist/rules.js
ADDED
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { fileURLToPath } from 'node:url';
|
|
2
|
+
import { resolve, dirname } from 'node:path';
|
|
3
|
+
import { existsSync, readdirSync, readFileSync } from 'node:fs';
|
|
4
|
+
const CONTENT_ROOT = resolve(dirname(fileURLToPath(import.meta.url)), '..');
|
|
5
|
+
const RULES_DIR = resolve(CONTENT_ROOT, 'resources', 'rules');
|
|
6
|
+
/**
|
|
7
|
+
* Filenames a rule may have. The id becomes a path segment in every project the
|
|
8
|
+
* CLI writes to, so anything else in the directory is ignored rather than
|
|
9
|
+
* trusted (overview-skill-crossreference-cost/DD-1).
|
|
10
|
+
*/
|
|
11
|
+
const RULE_FILE = /^([a-z0-9-]+)\.md$/;
|
|
12
|
+
/**
|
|
13
|
+
* Load every rule the overview skill points at instead of carrying.
|
|
14
|
+
*
|
|
15
|
+
* Each rule is stated once, in its own file, so a skill that cross-references
|
|
16
|
+
* one rule costs the reader that rule and not the whole overview. Both
|
|
17
|
+
* consumers call this: the CLI emits the files into `.aidlc/resources/rules/`,
|
|
18
|
+
* and the website renders them under the overview's docs page. One source, two
|
|
19
|
+
* consumers, no copy.
|
|
20
|
+
*
|
|
21
|
+
* @returns Rules sorted by id.
|
|
22
|
+
*/
|
|
23
|
+
export function loadRules() {
|
|
24
|
+
if (!existsSync(RULES_DIR))
|
|
25
|
+
return [];
|
|
26
|
+
return readdirSync(RULES_DIR)
|
|
27
|
+
.map((name) => RULE_FILE.exec(name)?.[1])
|
|
28
|
+
.filter((id) => id !== undefined)
|
|
29
|
+
.sort()
|
|
30
|
+
.map((id) => ({ id, body: readFileSync(resolve(RULES_DIR, `${id}.md`), 'utf8') }));
|
|
31
|
+
}
|
|
32
|
+
//# sourceMappingURL=rules.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rules.js","sourceRoot":"","sources":["../src/rules.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAC7C,OAAO,EAAE,UAAU,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,SAAS,CAAC;AAGhE,MAAM,YAAY,GAAG,OAAO,CAAC,OAAO,CAAC,aAAa,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,EAAE,IAAI,CAAC,CAAC;AAC5E,MAAM,SAAS,GAAG,OAAO,CAAC,YAAY,EAAE,WAAW,EAAE,OAAO,CAAC,CAAC;AAE9D;;;;GAIG;AACH,MAAM,SAAS,GAAG,oBAAoB,CAAC;AAEvC;;;;;;;;;;GAUG;AACH,MAAM,UAAU,SAAS;IACvB,IAAI,CAAC,UAAU,CAAC,SAAS,CAAC;QAAE,OAAO,EAAE,CAAC;IACtC,OAAO,WAAW,CAAC,SAAS,CAAC;SAC1B,GAAG,CAAC,CAAC,IAAI,EAAE,EAAE,CAAC,SAAS,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC;SACxC,MAAM,CAAC,CAAC,EAAE,EAAgB,EAAE,CAAC,EAAE,KAAK,SAAS,CAAC;SAC9C,IAAI,EAAE;SACN,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC,EAAE,EAAE,EAAE,IAAI,EAAE,YAAY,CAAC,OAAO,CAAC,SAAS,EAAE,GAAG,EAAE,KAAK,CAAC,EAAE,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC;AACvF,CAAC"}
|
package/dist/types.d.ts
CHANGED
|
@@ -19,6 +19,16 @@ export interface GuidanceLayer {
|
|
|
19
19
|
filename: string;
|
|
20
20
|
body: string;
|
|
21
21
|
}
|
|
22
|
+
/**
|
|
23
|
+
* One rule the overview skill points at instead of carrying — the only copy of
|
|
24
|
+
* its text (overview-skill-crossreference-cost/AC-1).
|
|
25
|
+
*/
|
|
26
|
+
export interface Rule {
|
|
27
|
+
/** Filename without `.md`; also the emitted file's name. Matches `^[a-z0-9-]+$`. */
|
|
28
|
+
id: string;
|
|
29
|
+
/** The whole file, H1 included. */
|
|
30
|
+
body: string;
|
|
31
|
+
}
|
|
22
32
|
/**
|
|
23
33
|
* One canonical vocabulary definition.
|
|
24
34
|
*
|
package/dist/types.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,KAAK;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,WAAW,EAAE,MAAM,CAAA;KAAE,CAAC;IAC3D,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAC9B;AAED,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;CACd;AAED;;;;;;;;;GASG;AACH,MAAM,WAAW,YAAY;IAC3B,4EAA4E;IAC5E,IAAI,EAAE,MAAM,CAAC;IACb,8EAA8E;IAC9E,UAAU,EAAE,MAAM,CAAC;IACnB;;;;;;;;OAQG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAED;;;;;;;;GAQG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;OAGG;IACH,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,gEAAgE;IAChE,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,aAAa;IAC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACtC,sEAAsE;IACtE,SAAS,CAAC,EAAE,iBAAiB,CAAC;CAC/B;AAED,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,YAAY,EAAE,MAAM,EAAE,CAAC;CACxB;AAED,MAAM,WAAW,UAAU;IACzB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,gBAAgB;IAC/B,UAAU,EAAE,OAAO,GAAG,UAAU,GAAG,OAAO,GAAG,UAAU,CAAC;IACxD,UAAU,EAAE,MAAM,CAAC;IACnB,GAAG,EAAE,MAAM,CAAC;CACb;AAED,wEAAwE;AACxE,MAAM,MAAM,UAAU,GAAG,YAAY,GAAG,YAAY,GAAG,YAAY,CAAC;AAEpE;;;;;;;;GAQG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,UAAU,CAAC;IACjB,EAAE,EAAE,MAAM,CAAC;IACX,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,UAAU,EAAE,CAAC;IAC1B,iBAAiB,EAAE,gBAAgB,EAAE,CAAC;IACtC,OAAO,EAAE,eAAe,EAAE,CAAC;CAC5B;AAED,MAAM,WAAW,QAAQ;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,YAAY,EAAE,CAAC;IACtB;;;;OAIG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,0EAA0E;IAC1E,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB"}
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,KAAK;IACpB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,WAAW,EAAE,MAAM,CAAA;KAAE,CAAC;IAC3D,IAAI,EAAE,MAAM,CAAC;CACd;AAED,MAAM,WAAW,gBAAgB;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,EAAE,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,GAAG,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAC9B;AAED,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;CACd;AAED;;;GAGG;AACH,MAAM,WAAW,IAAI;IACnB,oFAAoF;IACpF,EAAE,EAAE,MAAM,CAAC;IACX,mCAAmC;IACnC,IAAI,EAAE,MAAM,CAAC;CACd;AAED;;;;;;;;;GASG;AACH,MAAM,WAAW,YAAY;IAC3B,4EAA4E;IAC5E,IAAI,EAAE,MAAM,CAAC;IACb,8EAA8E;IAC9E,UAAU,EAAE,MAAM,CAAC;IACnB;;;;;;;;OAQG;IACH,GAAG,CAAC,EAAE,MAAM,CAAC;CACd;AAED;;;;;;;;GAQG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;OAGG;IACH,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,gEAAgE;IAChE,SAAS,EAAE,MAAM,CAAC;CACnB;AAED,MAAM,WAAW,aAAa;IAC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACtC,sEAAsE;IACtE,SAAS,CAAC,EAAE,iBAAiB,CAAC;CAC/B;AAED,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,YAAY,EAAE,MAAM,EAAE,CAAC;CACxB;AAED,MAAM,WAAW,UAAU;IACzB,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,MAAM,WAAW,gBAAgB;IAC/B,UAAU,EAAE,OAAO,GAAG,UAAU,GAAG,OAAO,GAAG,UAAU,CAAC;IACxD,UAAU,EAAE,MAAM,CAAC;IACnB,GAAG,EAAE,MAAM,CAAC;CACb;AAED,wEAAwE;AACxE,MAAM,MAAM,UAAU,GAAG,YAAY,GAAG,YAAY,GAAG,YAAY,CAAC;AAEpE;;;;;;;;GAQG;AACH,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,UAAU,CAAC;IACjB,EAAE,EAAE,MAAM,CAAC;IACX,GAAG,EAAE,MAAM,CAAC;CACb;AAED,MAAM,WAAW,YAAY;IAC3B,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,UAAU,EAAE,CAAC;IAC1B,iBAAiB,EAAE,gBAAgB,EAAE,CAAC;IACtC,OAAO,EAAE,eAAe,EAAE,CAAC;CAC5B;AAED,MAAM,WAAW,QAAQ;IACvB,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,YAAY,EAAE,CAAC;IACtB;;;;OAIG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,0EAA0E;IAC1E,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB"}
|
package/package.json
CHANGED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# The always-read rule
|
|
2
|
+
|
|
3
|
+
This file is the only statement of the rule. The phase skills point here instead of restating it, so there is no second copy to drift.
|
|
4
|
+
|
|
5
|
+
**Read the always-read set on entering a phase: every layer in `.aidlc/guidance/index.yaml` *except* those whose entry carries `on_demand: true`.** Read the index rather than assuming the layers named at the bottom of a skill are the only ones — a project can install a layer after its skills were emitted.
|
|
6
|
+
|
|
7
|
+
An `on_demand: true` layer is read **only when the phase has a stated reason to**. It is registered, active, and current; it is simply too large to be worth carrying in every session by default.
|
|
8
|
+
|
|
9
|
+
The two lessons layers are the reason the distinction exists:
|
|
10
|
+
|
|
11
|
+
- **`lessons-digest.md` is always-read.** A short distillation of the lessons this project has paid for more than once, regenerated by the **aidlc-retrospective** skill at consolidation.
|
|
12
|
+
- **`.aidlc/guidance/lessons.md` is on-demand, and it is the full corpus** — every lesson from every completed instance. Read it when you are touching a mechanism a past instance got wrong, when a gate keeps failing for reasons nobody can name, or when running consolidation. It grows by design (up to three lessons per instance), which is what makes an unconditional read a tax on every future session rather than a one-time cost.
|
|
13
|
+
|
|
14
|
+
Treat every lesson as a historical observation, not a directive. An entry naming a file, function, or flag may describe code a later instance renamed or deleted — check the source before acting on it.
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
# The constitution rule
|
|
2
|
+
|
|
3
|
+
This file is the only statement of the rule. Other skills point here instead of restating it, so there is no second copy to drift.
|
|
4
|
+
|
|
5
|
+
When `.aidlc/context/constitution.md` exists, read it before shaping work. It records what this repo owns (`IN-<n>` entries) and what it must never do (`NOT-<n>` entries), each citing the vision statement it was derived from. **If the work in front of you crosses a prohibition, name that prohibition by its id and say plainly that it does, before going further.** The user may still choose to proceed, or to amend the constitution — but the crossing gets stated out loud at the start rather than discovered in review.
|
|
6
|
+
|
|
7
|
+
The constitution never fails a gate and never blocks a transition; its whole force is that somebody read it out at the right moment. An absent file is a normal state, not a gap to fill — it is written by the **aidlc-constitution** skill, and only a project with a vision document to import has one.
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# The context rule
|
|
2
|
+
|
|
3
|
+
This file is the only statement of the rule. Every phase skill points here instead of
|
|
4
|
+
restating it, so there is no second copy to drift — and so the rule does not itself
|
|
5
|
+
become resident bytes in seven places.
|
|
6
|
+
|
|
7
|
+
**A phase boundary is where you start a fresh session.** Not a suggestion about tidiness:
|
|
8
|
+
91% of what a lifecycle run costs is re-reading the conversation it is already carrying,
|
|
9
|
+
and that carry only grows. Measured across 20,920 attributed records, average context per
|
|
10
|
+
unit of work runs 80k tokens in ideation, 164k in requirements, 259k in implementation,
|
|
11
|
+
395k in deployment and 791k in maintenance. Deployment is the most expensive phase in the
|
|
12
|
+
lifecycle — more than implementation — not because it does more, but because it runs last
|
|
13
|
+
and inherits everything before it. The one phase that reliably starts fresh does
|
|
14
|
+
comparable work at 76k.
|
|
15
|
+
|
|
16
|
+
Three things follow:
|
|
17
|
+
|
|
18
|
+
1. **Cross a phase boundary in a new session** whenever the platform allows it. The
|
|
19
|
+
lifecycle is designed for this: state lives in files, not in the conversation.
|
|
20
|
+
2. **Re-read only what the phase you are entering names.** Each phase skill lists exactly
|
|
21
|
+
that under *Entering in a fresh session*. The list is the whole list — an artifact not
|
|
22
|
+
on it is not needed to start, and reading it "for context" is the charge this rule
|
|
23
|
+
exists to avoid.
|
|
24
|
+
3. **Check the budget when you are unsure**: `aidlc cost context` reports the context this
|
|
25
|
+
session is carrying against a budget (default 150,000 tokens, configurable as
|
|
26
|
+
`cost.context_budget_tokens`). It reads the transcript, so it answers before any cost
|
|
27
|
+
capture has run.
|
|
28
|
+
|
|
29
|
+
**The budget never fails a gate and never blocks a transition.** Its whole force is that
|
|
30
|
+
somebody read it out at the right moment — the same force the constitution has, and for
|
|
31
|
+
the same reason. Going over budget is information, not a violation: a long
|
|
32
|
+
implementation phase may legitimately exceed it. What is not legitimate is carrying
|
|
33
|
+
requirements' conversation into deployment because nobody stopped to notice.
|
|
34
|
+
|
|
35
|
+
A caveat worth stating, because it decides whether the rule is worth following: a fresh
|
|
36
|
+
session re-reads some of what it would otherwise still hold, and that spends back part of
|
|
37
|
+
the saving. Every phase list below is bounded for exactly that reason. If re-reading turns
|
|
38
|
+
out to cost more than a third of the saving, the threshold should move — measure it rather
|
|
39
|
+
than assuming either way.
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# Creating an Instance
|
|
2
|
+
|
|
3
|
+
The `aidlc start` CLI automates this; when it is not available, create the instance directly:
|
|
4
|
+
|
|
5
|
+
0. **Concurrency gate first** (see the entry-point skill): when another live session holds a claim in this checkout, offer worktree / stop / no-code before creating anything.
|
|
6
|
+
1. Pick a template and scope (see **aidlc-getting-started** for template selection and per-template artifacts). The initial phase follows the scope: full → ideation, standard → requirements, micro → implementation.
|
|
7
|
+
2. Choose a URL-safe instance name and create `.aidlc/state/<name>/`. If the directory already exists, stop and ask for a different name. In a git repo, also register the instance in `<git-common-dir>/aidlc/registry/<name>.yaml` (fields: `name`, `branch`, `worktree_path`, `created_at`) — create-exclusively, never overwrite; if the file exists, another session owns the name.
|
|
8
|
+
3. Write `instance.yaml`:
|
|
9
|
+
```yaml
|
|
10
|
+
name: <instance-name>
|
|
11
|
+
template: <template-name>
|
|
12
|
+
scope: <full|standard|micro>
|
|
13
|
+
created_at: <ISO 8601 UTC>
|
|
14
|
+
created_by: <session-id or username>
|
|
15
|
+
current_phase: <initial-phase>
|
|
16
|
+
claim: null
|
|
17
|
+
scope_history: []
|
|
18
|
+
```
|
|
19
|
+
For a worktree instance add `branch: <its-branch>`; for a no-code instance add `branch: null` (blocks Implementation entry until a branch exists). Omit the field entirely otherwise.
|
|
20
|
+
4. Read the phase list and each phase's artifacts with `aidlc templates show <template> --scope <scope>` — **do not guess them, and do not copy them from another instance**. Different templates require different artifacts, and an instance seeded with artifacts its template never asked for fails its gates on files nobody needs. If the CLI is unavailable, the definitions are in `@rasensio/aidlc-content`'s `templates/` directory.
|
|
21
|
+
5. For each phase that command lists, write `phase-<name>.yaml`, using its artifact names verbatim:
|
|
22
|
+
```yaml
|
|
23
|
+
phase: <phase-name>
|
|
24
|
+
status: pending
|
|
25
|
+
owner: null
|
|
26
|
+
entered_at: null # except the initial phase, which gets created_at
|
|
27
|
+
completed_at: null
|
|
28
|
+
completed_by: null
|
|
29
|
+
skip_reason: null
|
|
30
|
+
artifacts:
|
|
31
|
+
- name: <artifact-name-from-templates-show>
|
|
32
|
+
status: not-started
|
|
33
|
+
metrics: { elapsed_seconds: 0 }
|
|
34
|
+
```
|
|
35
|
+
The initial phase takes `entered_at: <the instance's created_at>`. It is the one phase no transition ever enters, so leaving it null means it completes with `elapsed_seconds: 0` and drops out of every lead-time figure.
|
|
36
|
+
6. Fire the `on-instance-start` lifecycle actions (see **Lifecycle Actions** in **aidlc-overview**). Do not skip this — automation the user configured (branch creation, issue tracking, notifications) depends on it. When the instance was created via the worktree flow or as no-code, set `AIDLC_WORKTREE=1` in the action environment so the branch-creation action no-ops (the worktree flow already made its branch; a no-code instance must not get one).
|
|
37
|
+
7. Report the instance name, phases, state path, and any actions that fired, then begin the initial phase with its skill.
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# Lifecycle or Skill?
|
|
2
|
+
|
|
3
|
+
**The rule: lifecycle for changes to the system; skills for repeatable operations of the system.**
|
|
4
|
+
|
|
5
|
+
Not every task belongs in a lifecycle instance. Ask which of the two a request is:
|
|
6
|
+
|
|
7
|
+
- **A change to the system** — a new capability, a fix, a refactor, anything that alters what the
|
|
8
|
+
system can do. This goes through the lifecycle: phases, artifacts, gates.
|
|
9
|
+
- **A repeatable operation of the system** — running a chore the system already supports, over and
|
|
10
|
+
over, with the same steps each time. This belongs in a **skill**, not an instance.
|
|
11
|
+
|
|
12
|
+
Worked example, a blog application:
|
|
13
|
+
|
|
14
|
+
| Request | Which | Why |
|
|
15
|
+
|---|---|---|
|
|
16
|
+
| "Add a series feature so posts can belong to a series" | **Lifecycle** | The system cannot do this yet. New capability → requirements, design, tests. |
|
|
17
|
+
| "Publish a post about last week's release" | **Skill** | The system already supports posts. Same steps every time. Wrapping each post in phases is ceremony. |
|
|
18
|
+
|
|
19
|
+
Running an operational skill is **never** a lifecycle instance. Do not create an instance, claim, or
|
|
20
|
+
phase artifacts to publish a post, rotate a log, or regenerate a report.
|
|
21
|
+
|
|
22
|
+
## The escape hatch
|
|
23
|
+
|
|
24
|
+
An operation sometimes reveals a missing capability — you go to publish a post and discover the system
|
|
25
|
+
has no way to mark it as a draft. When that happens, the *operation* stops being the work and the
|
|
26
|
+
missing capability re-enters the lifecycle as a normal instance. Capture it with **aidlc-roadmap** or start
|
|
27
|
+
an instance; do not quietly extend the skill into building the feature.
|
|
28
|
+
|
|
29
|
+
## Quality mechanisms live inside the skill
|
|
30
|
+
|
|
31
|
+
An operational skill's output still needs checking — facts verified, schema validated, the build run,
|
|
32
|
+
links resolved. Those checks belong **inside the skill's own instructions**, not as lifecycle phases
|
|
33
|
+
wrapped around each invocation. A skill that carries its own verification produces checked output every
|
|
34
|
+
time it runs; a skill that relies on a review phase produces checked output only when someone remembers
|
|
35
|
+
to run one.
|
|
36
|
+
|
|
37
|
+
`aidlc add skill` scaffolds an operational skill with verification steps already embedded.
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
# Question Protocol
|
|
2
|
+
|
|
3
|
+
Ask the user something when **different answers would change an artifact, a design decision, or scope** — the trigger is consequence, not volume. A question whose answers change nothing is not asked. A question that an answer already given in this instance resolves is not re-asked: name that answer and ask the narrow follow-up instead.
|
|
4
|
+
|
|
5
|
+
## The spec
|
|
6
|
+
|
|
7
|
+
Every question is written first as a **spec** — platform-neutral, and never printed into the conversation. It carries, at minimum:
|
|
8
|
+
|
|
9
|
+
- **The decision**, as one interrogative sentence.
|
|
10
|
+
- **What it is** — what the thing being decided is and what it does, in plain words, shown on one concrete example with names, values or dates. Required on every question: the person answering owns the decision but was not in your research, and does not carry the vocabulary you just read. For an everyday concept this is one sentence; its length scales, its presence does not.
|
|
11
|
+
- **Why it matters** — what it blocks, and what goes wrong if it is guessed.
|
|
12
|
+
- **What the repo already says** — cited as `path:line`, or `path` when the whole file is the point. "Nothing found" is a valid citation; saying nothing is not. Schema terms, mechanism names and citations belong here, not in the options.
|
|
13
|
+
- **Two to four options**, each defined by its observable effect — who sees what, what gets rejected, what gets flagged — with its consequence spelled out. Say what would happen, not how it would be built.
|
|
14
|
+
- **A recommendation**, marked as such — exactly one, with the reason it wins.
|
|
15
|
+
- **If you say nothing** — the outcome of no answer, so that not answering is a choice rather than a stall.
|
|
16
|
+
|
|
17
|
+
When several questions in one file share a concept, open the file with one shared primer that explains it, and have every question reuse the same running example rather than inventing a new one. The reader learns the example once and then sees each option applied to it.
|
|
18
|
+
|
|
19
|
+
The example shows what would really happen. One simplified until it changes the answer misleads as badly as jargon does, and it is harder to spot.
|
|
20
|
+
|
|
21
|
+
Expand every identifier on first use, writing the thing out with the tag in parentheses — "the citation rule (AC-1)", not a bare `AC-1`, `FR3` or `unit-4`. A bare tag assumes the reader carries a mapping they do not have.
|
|
22
|
+
|
|
23
|
+
## Rendering the spec
|
|
24
|
+
|
|
25
|
+
The spec is input to a rendering, never output. How to render it on this platform is in `.aidlc/resources/questions/rendering.md` — read that before asking. Routing is decided by the question, never by asking the user which mode they want:
|
|
26
|
+
|
|
27
|
+
- Options self-explanatory and the stake fits one line → render it directly and let the user answer in place.
|
|
28
|
+
- Needs citations, trade-offs, or more than three lines of context → write the question file first, then render a prompt naming its path in one line.
|
|
29
|
+
|
|
30
|
+
## The question file
|
|
31
|
+
|
|
32
|
+
Written in **every** branch, including when the user answers in place — it is the record of what was asked and decided, not a fallback. Two locations, and no others are valid:
|
|
33
|
+
|
|
34
|
+
- Inside an instance: `.aidlc/state/<instance>/<phase>-questions.md`.
|
|
35
|
+
- No instance (constitution update, first activation): `.aidlc/questions/<topic>.md`.
|
|
36
|
+
|
|
37
|
+
Each question in the file ends with an `[Answer]:` tag — blank while open, carrying the chosen option label verbatim once answered. Fold answers into the phase artifact they were gathered for and leave the file in place as the record.
|
|
38
|
+
|
|
39
|
+
With no interactive terminal, write the file, say where it is, and end the turn. Never assume an answer.
|
|
40
|
+
|
|
41
|
+
**At most five questions stand open at once.** At the limit, answering — or accepting the stated defaults — comes before asking another. The cap counts open questions, not questions asked: a long negotiation is fine, an accumulating pile is not.
|
package/skills/00-overview.md
CHANGED
|
@@ -43,41 +43,7 @@ The AIDLC defines seven ordered phases. Not all apply to every task:
|
|
|
43
43
|
|
|
44
44
|
## Lifecycle or Skill?
|
|
45
45
|
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
Not every task belongs in a lifecycle instance. Ask which of the two a request is:
|
|
49
|
-
|
|
50
|
-
- **A change to the system** — a new capability, a fix, a refactor, anything that alters what the
|
|
51
|
-
system can do. This goes through the lifecycle: phases, artifacts, gates.
|
|
52
|
-
- **A repeatable operation of the system** — running a chore the system already supports, over and
|
|
53
|
-
over, with the same steps each time. This belongs in a **skill**, not an instance.
|
|
54
|
-
|
|
55
|
-
Worked example, a blog application:
|
|
56
|
-
|
|
57
|
-
| Request | Which | Why |
|
|
58
|
-
|---|---|---|
|
|
59
|
-
| "Add a series feature so posts can belong to a series" | **Lifecycle** | The system cannot do this yet. New capability → requirements, design, tests. |
|
|
60
|
-
| "Publish a post about last week's release" | **Skill** | The system already supports posts. Same steps every time. Wrapping each post in phases is ceremony. |
|
|
61
|
-
|
|
62
|
-
Running an operational skill is **never** a lifecycle instance. Do not create an instance, claim, or
|
|
63
|
-
phase artifacts to publish a post, rotate a log, or regenerate a report.
|
|
64
|
-
|
|
65
|
-
### The escape hatch
|
|
66
|
-
|
|
67
|
-
An operation sometimes reveals a missing capability — you go to publish a post and discover the system
|
|
68
|
-
has no way to mark it as a draft. When that happens, the *operation* stops being the work and the
|
|
69
|
-
missing capability re-enters the lifecycle as a normal instance. Capture it with **aidlc-roadmap** or start
|
|
70
|
-
an instance; do not quietly extend the skill into building the feature.
|
|
71
|
-
|
|
72
|
-
### Quality mechanisms live inside the skill
|
|
73
|
-
|
|
74
|
-
An operational skill's output still needs checking — facts verified, schema validated, the build run,
|
|
75
|
-
links resolved. Those checks belong **inside the skill's own instructions**, not as lifecycle phases
|
|
76
|
-
wrapped around each invocation. A skill that carries its own verification produces checked output every
|
|
77
|
-
time it runs; a skill that relies on a review phase produces checked output only when someone remembers
|
|
78
|
-
to run one.
|
|
79
|
-
|
|
80
|
-
`aidlc add skill` scaffolds an operational skill with verification steps already embedded.
|
|
46
|
+
Whether a request is a lifecycle instance or an operational skill, and what to do when an operation turns out to need a new capability. The rule is in `.aidlc/resources/rules/lifecycle-or-skill.md`.
|
|
81
47
|
|
|
82
48
|
## State Protocol
|
|
83
49
|
|
|
@@ -107,41 +73,7 @@ Each line in `transitions.log` is a JSON object:
|
|
|
107
73
|
|
|
108
74
|
### Creating an Instance
|
|
109
75
|
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
0. **Concurrency gate first** (see the entry-point skill): when another live session holds a claim in this checkout, offer worktree / stop / no-code before creating anything.
|
|
113
|
-
1. Pick a template and scope (see **aidlc-getting-started** for template selection and per-template artifacts). The initial phase follows the scope: full → ideation, standard → requirements, micro → implementation.
|
|
114
|
-
2. Choose a URL-safe instance name and create `.aidlc/state/<name>/`. If the directory already exists, stop and ask for a different name. In a git repo, also register the instance in `<git-common-dir>/aidlc/registry/<name>.yaml` (fields: `name`, `branch`, `worktree_path`, `created_at`) — create-exclusively, never overwrite; if the file exists, another session owns the name.
|
|
115
|
-
3. Write `instance.yaml`:
|
|
116
|
-
```yaml
|
|
117
|
-
name: <instance-name>
|
|
118
|
-
template: <template-name>
|
|
119
|
-
scope: <full|standard|micro>
|
|
120
|
-
created_at: <ISO 8601 UTC>
|
|
121
|
-
created_by: <session-id or username>
|
|
122
|
-
current_phase: <initial-phase>
|
|
123
|
-
claim: null
|
|
124
|
-
scope_history: []
|
|
125
|
-
```
|
|
126
|
-
For a worktree instance add `branch: <its-branch>`; for a no-code instance add `branch: null` (blocks Implementation entry until a branch exists). Omit the field entirely otherwise.
|
|
127
|
-
4. Read the phase list and each phase's artifacts with `aidlc templates show <template> --scope <scope>` — **do not guess them, and do not copy them from another instance**. Different templates require different artifacts, and an instance seeded with artifacts its template never asked for fails its gates on files nobody needs. If the CLI is unavailable, the definitions are in `@rasensio/aidlc-content`'s `templates/` directory.
|
|
128
|
-
5. For each phase that command lists, write `phase-<name>.yaml`, using its artifact names verbatim:
|
|
129
|
-
```yaml
|
|
130
|
-
phase: <phase-name>
|
|
131
|
-
status: pending
|
|
132
|
-
owner: null
|
|
133
|
-
entered_at: null # except the initial phase, which gets created_at
|
|
134
|
-
completed_at: null
|
|
135
|
-
completed_by: null
|
|
136
|
-
skip_reason: null
|
|
137
|
-
artifacts:
|
|
138
|
-
- name: <artifact-name-from-templates-show>
|
|
139
|
-
status: not-started
|
|
140
|
-
metrics: { elapsed_seconds: 0 }
|
|
141
|
-
```
|
|
142
|
-
The initial phase takes `entered_at: <the instance's created_at>`. It is the one phase no transition ever enters, so leaving it null means it completes with `elapsed_seconds: 0` and drops out of every lead-time figure.
|
|
143
|
-
6. Fire the `on-instance-start` lifecycle actions (see **Lifecycle Actions**). Do not skip this — automation the user configured (branch creation, issue tracking, notifications) depends on it. When the instance was created via the worktree flow or as no-code, set `AIDLC_WORKTREE=1` in the action environment so the branch-creation action no-ops (the worktree flow already made its branch; a no-code instance must not get one).
|
|
144
|
-
7. Report the instance name, phases, state path, and any actions that fired, then begin the initial phase with its skill.
|
|
76
|
+
Creating an instance by hand when the `aidlc start` CLI is not available. The rule is in `.aidlc/resources/rules/creating-an-instance.md`.
|
|
145
77
|
|
|
146
78
|
## Lifecycle Actions
|
|
147
79
|
|
|
@@ -158,45 +90,7 @@ On each lifecycle event — `on-instance-start`, `on-phase-enter`, `on-phase-exi
|
|
|
158
90
|
|
|
159
91
|
## Question Protocol
|
|
160
92
|
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
### The spec
|
|
164
|
-
|
|
165
|
-
Every question is written first as a **spec** — platform-neutral, and never printed into the conversation. It carries, at minimum:
|
|
166
|
-
|
|
167
|
-
- **The decision**, as one interrogative sentence.
|
|
168
|
-
- **What it is** — what the thing being decided is and what it does, in plain words, shown on one concrete example with names, values or dates. Required on every question: the person answering owns the decision but was not in your research, and does not carry the vocabulary you just read. For an everyday concept this is one sentence; its length scales, its presence does not.
|
|
169
|
-
- **Why it matters** — what it blocks, and what goes wrong if it is guessed.
|
|
170
|
-
- **What the repo already says** — cited as `path:line`, or `path` when the whole file is the point. "Nothing found" is a valid citation; saying nothing is not. Schema terms, mechanism names and citations belong here, not in the options.
|
|
171
|
-
- **Two to four options**, each defined by its observable effect — who sees what, what gets rejected, what gets flagged — with its consequence spelled out. Say what would happen, not how it would be built.
|
|
172
|
-
- **A recommendation**, marked as such — exactly one, with the reason it wins.
|
|
173
|
-
- **If you say nothing** — the outcome of no answer, so that not answering is a choice rather than a stall.
|
|
174
|
-
|
|
175
|
-
When several questions in one file share a concept, open the file with one shared primer that explains it, and have every question reuse the same running example rather than inventing a new one. The reader learns the example once and then sees each option applied to it.
|
|
176
|
-
|
|
177
|
-
The example shows what would really happen. One simplified until it changes the answer misleads as badly as jargon does, and it is harder to spot.
|
|
178
|
-
|
|
179
|
-
Expand every identifier on first use, writing the thing out with the tag in parentheses — "the citation rule (AC-1)", not a bare `AC-1`, `FR3` or `unit-4`. A bare tag assumes the reader carries a mapping they do not have.
|
|
180
|
-
|
|
181
|
-
### Rendering the spec
|
|
182
|
-
|
|
183
|
-
The spec is input to a rendering, never output. How to render it on this platform is in `.aidlc/resources/questions/rendering.md` — read that before asking. Routing is decided by the question, never by asking the user which mode they want:
|
|
184
|
-
|
|
185
|
-
- Options self-explanatory and the stake fits one line → render it directly and let the user answer in place.
|
|
186
|
-
- Needs citations, trade-offs, or more than three lines of context → write the question file first, then render a prompt naming its path in one line.
|
|
187
|
-
|
|
188
|
-
### The question file
|
|
189
|
-
|
|
190
|
-
Written in **every** branch, including when the user answers in place — it is the record of what was asked and decided, not a fallback. Two locations, and no others are valid:
|
|
191
|
-
|
|
192
|
-
- Inside an instance: `.aidlc/state/<instance>/<phase>-questions.md`.
|
|
193
|
-
- No instance (constitution update, first activation): `.aidlc/questions/<topic>.md`.
|
|
194
|
-
|
|
195
|
-
Each question in the file ends with an `[Answer]:` tag — blank while open, carrying the chosen option label verbatim once answered. Fold answers into the phase artifact they were gathered for and leave the file in place as the record.
|
|
196
|
-
|
|
197
|
-
With no interactive terminal, write the file, say where it is, and end the turn. Never assume an answer.
|
|
198
|
-
|
|
199
|
-
**At most five questions stand open at once.** At the limit, answering — or accepting the stated defaults — comes before asking another. The cap counts open questions, not questions asked: a long negotiation is fine, an accumulating pile is not.
|
|
93
|
+
When to ask the user something, how the question is written, and where it is recorded. The rule is in `.aidlc/resources/rules/question-protocol.md`.
|
|
200
94
|
|
|
201
95
|
## Roadmap Capture
|
|
202
96
|
|
|
@@ -239,26 +133,11 @@ An instance's **completion moment** is when the last applicable phase (template
|
|
|
239
133
|
|
|
240
134
|
### The always-read rule
|
|
241
135
|
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
**Read the always-read set on entering a phase: every layer in `.aidlc/guidance/index.yaml` *except* those whose entry carries `on_demand: true`.** Read the index rather than assuming the layers named at the bottom of a skill are the only ones — a project can install a layer after its skills were emitted.
|
|
245
|
-
|
|
246
|
-
An `on_demand: true` layer is read **only when the phase has a stated reason to**. It is registered, active, and current; it is simply too large to be worth carrying in every session by default.
|
|
247
|
-
|
|
248
|
-
The two lessons layers are the reason the distinction exists:
|
|
249
|
-
|
|
250
|
-
- **`lessons-digest.md` is always-read.** A short distillation of the lessons this project has paid for more than once, regenerated by the **aidlc-retrospective** skill at consolidation.
|
|
251
|
-
- **`.aidlc/guidance/lessons.md` is on-demand, and it is the full corpus** — every lesson from every completed instance. Read it when you are touching a mechanism a past instance got wrong, when a gate keeps failing for reasons nobody can name, or when running consolidation. It grows by design (up to three lessons per instance), which is what makes an unconditional read a tax on every future session rather than a one-time cost.
|
|
252
|
-
|
|
253
|
-
Treat every lesson as a historical observation, not a directive. An entry naming a file, function, or flag may describe code a later instance renamed or deleted — check the source before acting on it.
|
|
136
|
+
Which guidance layers to read on entering a phase, and when to reach for the full `lessons.md`. The rule is in `.aidlc/resources/rules/always-read.md`.
|
|
254
137
|
|
|
255
138
|
### The constitution rule
|
|
256
139
|
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
When `.aidlc/context/constitution.md` exists, read it before shaping work. It records what this repo owns (`IN-<n>` entries) and what it must never do (`NOT-<n>` entries), each citing the vision statement it was derived from. **If the work in front of you crosses a prohibition, name that prohibition by its id and say plainly that it does, before going further.** The user may still choose to proceed, or to amend the constitution — but the crossing gets stated out loud at the start rather than discovered in review.
|
|
260
|
-
|
|
261
|
-
The constitution never fails a gate and never blocks a transition; its whole force is that somebody read it out at the right moment. An absent file is a normal state, not a gap to fill — it is written by the **aidlc-constitution** skill, and only a project with a vision document to import has one.
|
|
140
|
+
What to do before shaping work when `.aidlc/context/constitution.md` exists. The rule is in `.aidlc/resources/rules/constitution.md`.
|
|
262
141
|
|
|
263
142
|
## Security
|
|
264
143
|
|
|
@@ -277,40 +156,4 @@ Never store credentials, tokens, or secrets in state files or artifacts.
|
|
|
277
156
|
|
|
278
157
|
### The context rule
|
|
279
158
|
|
|
280
|
-
|
|
281
|
-
restating it, so there is no second copy to drift — and so the rule does not itself
|
|
282
|
-
become resident bytes in seven places.
|
|
283
|
-
|
|
284
|
-
**A phase boundary is where you start a fresh session.** Not a suggestion about tidiness:
|
|
285
|
-
91% of what a lifecycle run costs is re-reading the conversation it is already carrying,
|
|
286
|
-
and that carry only grows. Measured across 20,920 attributed records, average context per
|
|
287
|
-
unit of work runs 80k tokens in ideation, 164k in requirements, 259k in implementation,
|
|
288
|
-
395k in deployment and 791k in maintenance. Deployment is the most expensive phase in the
|
|
289
|
-
lifecycle — more than implementation — not because it does more, but because it runs last
|
|
290
|
-
and inherits everything before it. The one phase that reliably starts fresh does
|
|
291
|
-
comparable work at 76k.
|
|
292
|
-
|
|
293
|
-
Three things follow:
|
|
294
|
-
|
|
295
|
-
1. **Cross a phase boundary in a new session** whenever the platform allows it. The
|
|
296
|
-
lifecycle is designed for this: state lives in files, not in the conversation.
|
|
297
|
-
2. **Re-read only what the phase you are entering names.** Each phase skill lists exactly
|
|
298
|
-
that under *Entering in a fresh session*. The list is the whole list — an artifact not
|
|
299
|
-
on it is not needed to start, and reading it "for context" is the charge this rule
|
|
300
|
-
exists to avoid.
|
|
301
|
-
3. **Check the budget when you are unsure**: `aidlc cost context` reports the context this
|
|
302
|
-
session is carrying against a budget (default 150,000 tokens, configurable as
|
|
303
|
-
`cost.context_budget_tokens`). It reads the transcript, so it answers before any cost
|
|
304
|
-
capture has run.
|
|
305
|
-
|
|
306
|
-
**The budget never fails a gate and never blocks a transition.** Its whole force is that
|
|
307
|
-
somebody read it out at the right moment — the same force the constitution has, and for
|
|
308
|
-
the same reason. Going over budget is information, not a violation: a long
|
|
309
|
-
implementation phase may legitimately exceed it. What is not legitimate is carrying
|
|
310
|
-
requirements' conversation into deployment because nobody stopped to notice.
|
|
311
|
-
|
|
312
|
-
A caveat worth stating, because it decides whether the rule is worth following: a fresh
|
|
313
|
-
session re-reads some of what it would otherwise still hold, and that spends back part of
|
|
314
|
-
the saving. Every phase list below is bounded for exactly that reason. If re-reading turns
|
|
315
|
-
out to cost more than a third of the saving, the threshold should move — measure it rather
|
|
316
|
-
than assuming either way.
|
|
159
|
+
Why a phase boundary is where a fresh session starts, and what to re-read after one. The rule is in `.aidlc/resources/rules/context.md`.
|
|
@@ -34,7 +34,7 @@ All lifecycle work runs on instances — YAML state under `.aidlc/state/<name>/`
|
|
|
34
34
|
|
|
35
35
|
> {{glossary:instance}}
|
|
36
36
|
|
|
37
|
-
1. Create a lifecycle instance from the `bugfix` template (see
|
|
37
|
+
1. Create a lifecycle instance from the `bugfix` template (see **Creating an Instance** (`.aidlc/resources/rules/creating-an-instance.md`)).
|
|
38
38
|
2. This gives a focused workflow: reproduce the bug → fix it → test it → deploy. The bugfix template skips the design phase and requires a `reproduction.md` artifact first.
|
|
39
39
|
3. Follow **aidlc-continue** at any point to pick up the next step.
|
|
40
40
|
|
|
@@ -49,7 +49,7 @@ Create an instance from the template that fits:
|
|
|
49
49
|
|
|
50
50
|
No. The rule is: **lifecycle for changes to the system; skills for repeatable operations of the system.** Publishing
|
|
51
51
|
a post, rotating a log, regenerating a report — the system already supports these, so they belong in a
|
|
52
|
-
skill rather than a lifecycle instance. See
|
|
52
|
+
skill rather than a lifecycle instance. See **Lifecycle or Skill?** (`.aidlc/resources/rules/lifecycle-or-skill.md`) for the rule, the
|
|
53
53
|
escape hatch when an operation reveals a missing capability, and a worked example.
|
|
54
54
|
|
|
55
55
|
Run `aidlc add skill <name>` to scaffold one with verification steps already built in. If you would
|
package/skills/03-entry-point.md
CHANGED
|
@@ -60,9 +60,9 @@ If `.aidlc/state/` is empty or missing, offer just three options: start somethin
|
|
|
60
60
|
| Choice | Action |
|
|
61
61
|
|--------|--------|
|
|
62
62
|
| Continue an instance | Follow the **aidlc-continue** skill |
|
|
63
|
-
| Start something new | Run the **concurrency gate** (below), then ask what they are building, pick a template (see **aidlc-getting-started**), and create the instance per
|
|
63
|
+
| Start something new | Run the **concurrency gate** (below), then ask what they are building, pick a template (see **aidlc-getting-started**), and create the instance per **Creating an Instance** (`.aidlc/resources/rules/creating-an-instance.md`) |
|
|
64
64
|
| Capture a roadmap item | Follow the **aidlc-roadmap** skill (capture flow) |
|
|
65
|
-
| Answer pending questions | Open the question file, re-render its open questions per the **Question Protocol**
|
|
65
|
+
| Answer pending questions | Open the question file, re-render its open questions per the **Question Protocol** (`.aidlc/resources/rules/question-protocol.md`), record each answer in the file, then fold them into the artifact they were gathered for |
|
|
66
66
|
| Triage the inbox | Follow the **aidlc-roadmap** skill (triage flow) |
|
|
67
67
|
| Browse / promote the roadmap | Follow the **aidlc-roadmap** skill (browse/promote flow) |
|
|
68
68
|
| Show status | Summarize each instance from its state files — name, template, current phase, completion %, and whether it looks stalled. When the roadmap is non-empty, append the per-status counts (e.g. "roadmap: 3 inbox, 5 backlog, 12 done") |
|
package/skills/04-roadmap.md
CHANGED
|
@@ -155,7 +155,7 @@ Work you agree with but cannot start — gated on a trigger, a decision, or some
|
|
|
155
155
|
|
|
156
156
|
Triage is the one flow that reads into the body, and it reads **the executive summary and nothing else**. Six labelled lines per item is what makes triaging a full inbox in one sitting possible; opening whole items is what makes triage something nobody ever gets round to. Show the summary, say which way you would go and why, and let the human decide. If an item has no executive summary, write one from what the item says before asking for a decision — a decision made without one is a decision made twice.
|
|
157
157
|
|
|
158
|
-
Read `.aidlc/context/constitution.md` when it exists and apply the constitution rule in
|
|
158
|
+
Read `.aidlc/context/constitution.md` when it exists and apply the constitution rule in `.aidlc/resources/rules/constitution.md`: an item that crosses a prohibition is the clearest `hold/` there is, and naming the prohibition turns "not for us" into a reason the submitter can read.
|
|
159
159
|
|
|
160
160
|
## Promote
|
|
161
161
|
|
|
@@ -166,7 +166,7 @@ Promotion is where the roadmap meets the lifecycle:
|
|
|
166
166
|
1. Promote from `backlog/` normally; from `inbox/` only when the user is explicitly skipping triage.
|
|
167
167
|
2. If the item's `depends_on` names items that are not yet `done`, say so and confirm before proceeding — promoting out of order is allowed but should be deliberate.
|
|
168
168
|
3. Choose a template and scope as usual (defaults from `.aidlc/config.yaml`; see **aidlc-getting-started**).
|
|
169
|
-
4. Create the instance per
|
|
169
|
+
4. Create the instance per **Creating an Instance** (`.aidlc/resources/rules/creating-an-instance.md`) — including firing `on-instance-start` lifecycle actions.
|
|
170
170
|
5. Seed the instance with the item: Full scope → the item is raw material the Ideation phase refines into that phase's required artifact (`idea.md` for the feature templates, `research-question.md` for `spike`); Standard scope → the item is input context for Requirements.
|
|
171
171
|
6. Set `promoted_to: <instance-name>`, move the file to `in-progress/`, and append the `history` entry.
|
|
172
172
|
|
|
@@ -136,7 +136,7 @@ risk, and it exits 0 either way. This is advisory. It never fails a phase.
|
|
|
136
136
|
|
|
137
137
|
A constitution update has no instance, so its questions go to
|
|
138
138
|
`.aidlc/questions/constitution-update-<YYYY-MM-DD>.md` — one question per change,
|
|
139
|
-
following the **Question Protocol**
|
|
139
|
+
following the **Question Protocol** (`.aidlc/resources/rules/question-protocol.md`):
|
|
140
140
|
|
|
141
141
|
```markdown
|
|
142
142
|
# Constitution update — <date>
|
package/skills/10-ideation.md
CHANGED
|
@@ -26,7 +26,7 @@ Ideation is the cheapest phase to enter because it inherits nothing. Read only:
|
|
|
26
26
|
- `.aidlc/context/constitution.md`, when it exists
|
|
27
27
|
|
|
28
28
|
Nothing else. There is no prior artifact to re-read; that is the whole advantage of
|
|
29
|
-
starting here. See **The context rule**
|
|
29
|
+
starting here. See **The context rule** (`.aidlc/resources/rules/context.md`) for why this list is a list.
|
|
30
30
|
|
|
31
31
|
## Required Artifacts
|
|
32
32
|
|
|
@@ -41,7 +41,7 @@ and open questions.
|
|
|
41
41
|
|
|
42
42
|
> {{glossary:artifact}}
|
|
43
43
|
|
|
44
|
-
1. **Consult the knowledge graph first.** If the project has a knowledge graph (`.aidlc/knowledge/` exists), run `aidlc knowledge context --scope phase --phase ideation` before exploring the codebase — it is the cheapest way to find where in the code to look, and re-exploring what it already covers wastes the phase. It is an index, not an authority: a specific symbol it names may have been renamed or deleted by a later instance, so open the source before treating any named component, table, or registry as real. Also read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule**
|
|
44
|
+
1. **Consult the knowledge graph first.** If the project has a knowledge graph (`.aidlc/knowledge/` exists), run `aidlc knowledge context --scope phase --phase ideation` before exploring the codebase — it is the cheapest way to find where in the code to look, and re-exploring what it already covers wastes the phase. It is an index, not an authority: a specific symbol it names may have been renamed or deleted by a later instance, so open the source before treating any named component, table, or registry as real. Also read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule** (`.aidlc/resources/rules/always-read.md`) for which layers those are and when to reach for the full `lessons.md`.
|
|
45
45
|
2. **Clarify the problem.** Ask the user what they want to build and why. Identify the core need vs. nice-to-haves.
|
|
46
46
|
3. **Explore constraints.** Document: timeline, technical constraints, platform limitations, team size, budget considerations.
|
|
47
47
|
4. **Generate options.** Propose 2-3 approaches. For each, note trade-offs (complexity, time, risk).
|
|
@@ -25,11 +25,11 @@ Read only:
|
|
|
25
25
|
- the ideation artifact (`idea.md`, or `research-question.md` for `spike`) — Full scope only
|
|
26
26
|
- the roadmap item this instance was promoted from — Standard scope, where it replaces the
|
|
27
27
|
ideation artifact as input
|
|
28
|
-
- the always-read guidance layers named in `.aidlc/guidance/index.yaml` (see **The always-read rule**
|
|
28
|
+
- the always-read guidance layers named in `.aidlc/guidance/index.yaml` (see **The always-read rule** (`.aidlc/resources/rules/always-read.md`))
|
|
29
29
|
- `.aidlc/context/constitution.md`, when it exists
|
|
30
30
|
|
|
31
31
|
Not the ideation *conversation* — the artifact is what it was written for.
|
|
32
|
-
See **The context rule**
|
|
32
|
+
See **The context rule** (`.aidlc/resources/rules/context.md`).
|
|
33
33
|
|
|
34
34
|
## Required Artifacts
|
|
35
35
|
|
|
@@ -39,7 +39,7 @@ See **The context rule** in **aidlc-overview**.
|
|
|
39
39
|
|
|
40
40
|
> {{glossary:artifact}}
|
|
41
41
|
|
|
42
|
-
1. **Gather requirements.** If a Full scope, read the ideation phase's artifact for context (`idea.md` for the feature templates, `research-question.md` for `spike`; `phase-ideation.yaml` names it). Otherwise, ask the user to describe desired behavior. Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule**
|
|
42
|
+
1. **Gather requirements.** If a Full scope, read the ideation phase's artifact for context (`idea.md` for the feature templates, `research-question.md` for `spike`; `phase-ideation.yaml` names it). Otherwise, ask the user to describe desired behavior. Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule** (`.aidlc/resources/rules/always-read.md`) for which layers those are and when to reach for the full `lessons.md`. Read `.aidlc/context/constitution.md` when it exists and apply the constitution rule in `.aidlc/resources/rules/constitution.md`.
|
|
43
43
|
2. **Write user stories.** Use the format: "As a [role], I want [capability], so that [benefit]."
|
|
44
44
|
3. **Define acceptance criteria.** Each criterion must be:
|
|
45
45
|
- Specific and unambiguous
|
|
@@ -48,7 +48,7 @@ See **The context rule** in **aidlc-overview**.
|
|
|
48
48
|
- **Identified**: write every criterion as a list item `- AC-<n>: <text>` (bold variants `- **AC-<n>**: ...` and `- **AC-<n>:** ...` are also valid). Assign `AC-1`, `AC-2`, ... sequentially. IDs are never renumbered or reused — an amended criterion keeps its meaning or is retired: mark it `- AC-<n> (retired YYYY-MM-DD, superseded by AC-<m>): <text>` and issue a new ID. The testing-phase gate parses these IDs and fails on any active criterion without a referencing test.
|
|
49
49
|
4. **Set scope boundaries.** Explicitly state what is NOT included.
|
|
50
50
|
5. **Non-functional requirements.** Address performance, security, accessibility, and compatibility where relevant.
|
|
51
|
-
6. **For open decisions**: When a decision would change what `requirements.md` says, ask it through the **Question Protocol**
|
|
51
|
+
6. **For open decisions**: When a decision would change what `requirements.md` says, ask it through the **Question Protocol** (`.aidlc/resources/rules/question-protocol.md`) — questions for this phase go to `.aidlc/state/<instance>/requirements-questions.md`. Prefer drafting `requirements.md` early with the unresolved points marked as explicit decision blocks: users decide better reacting to a concrete draft than answering abstract questions. Fold each answer into the draft and leave the question file as the record of what was decided and why.
|
|
52
52
|
|
|
53
53
|
## Bugfix Reproduction (bugfix template)
|
|
54
54
|
|
package/skills/30-design.md
CHANGED
|
@@ -23,13 +23,13 @@ Read only:
|
|
|
23
23
|
|
|
24
24
|
- `instance.yaml`
|
|
25
25
|
- `requirements.md` — in full; the acceptance criteria are what the design is traced against
|
|
26
|
-
- the always-read guidance layers named in `.aidlc/guidance/index.yaml` (see **The always-read rule**
|
|
26
|
+
- the always-read guidance layers named in `.aidlc/guidance/index.yaml` (see **The always-read rule** (`.aidlc/resources/rules/always-read.md`))
|
|
27
27
|
- `.aidlc/context/architecture.md` and `style-guide.md`
|
|
28
28
|
- `.aidlc/context/constitution.md`, when it exists
|
|
29
29
|
|
|
30
30
|
The seams the requirements touch are then read from the *source*, as step 3 of the
|
|
31
31
|
instructions says — a handful of files, not a survey, and not the previous phase's
|
|
32
|
-
transcript. See **The context rule**
|
|
32
|
+
transcript. See **The context rule** (`.aidlc/resources/rules/context.md`).
|
|
33
33
|
|
|
34
34
|
## Required Artifacts
|
|
35
35
|
|
|
@@ -40,7 +40,7 @@ transcript. See **The context rule** in **aidlc-overview**.
|
|
|
40
40
|
> {{glossary:gate}}
|
|
41
41
|
|
|
42
42
|
1. **Review requirements.** Read `requirements.md` (or its summary if one exists). Identify the key technical challenges. When requirements carry `AC-n` IDs, note in each design section which criteria it addresses — that linkage is what reviewers and the testing phase trace against.
|
|
43
|
-
2. **Consult the knowledge graph, then check it against the source.** If the project has a knowledge graph (`.aidlc/knowledge/` exists), run `aidlc knowledge context --scope phase --phase design` for existing architecture, decisions, and conventions. The graph is an index into the code, not an authority over it: an entry naming a component, table, column, function, or registry is a pointer to open, and an entry written by an earlier instance may name something a later one renamed or deleted. Confirm a named symbol exists in the source before designing against it — `aidlc knowledge verify <id>` records that you did, and `aidlc knowledge update <id>` corrects an entry that no longer matches. A design built on a symbol that is not there produces code against an API nobody has, and nothing downstream catches it until implementation. Also read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule**
|
|
43
|
+
2. **Consult the knowledge graph, then check it against the source.** If the project has a knowledge graph (`.aidlc/knowledge/` exists), run `aidlc knowledge context --scope phase --phase design` for existing architecture, decisions, and conventions. The graph is an index into the code, not an authority over it: an entry naming a component, table, column, function, or registry is a pointer to open, and an entry written by an earlier instance may name something a later one renamed or deleted. Confirm a named symbol exists in the source before designing against it — `aidlc knowledge verify <id>` records that you did, and `aidlc knowledge update <id>` corrects an entry that no longer matches. A design built on a symbol that is not there produces code against an API nobody has, and nothing downstream catches it until implementation. Also read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule** (`.aidlc/resources/rules/always-read.md`) for which layers those are and when to reach for the full `lessons.md`. Read `.aidlc/context/constitution.md` when it exists and apply the constitution rule in `.aidlc/resources/rules/constitution.md`.
|
|
44
44
|
3. **Find the seams before proposing structure.** A project is brownfield from its second instance onwards, so start from the assumption that something in the codebase already does part of what the requirements ask for. For each capability in `requirements.md`, locate and read the existing code that carries any of it — the scheduler that already fires, the settings shape that already persists, the registry that already dispatches — and name those files in `design.md` before describing a single new component. Keep it narrow: the seams the requirements actually touch, a handful of files, not a survey. When nothing exists, write that down — "no existing seam" is a finding, and stating it is what separates a genuinely new component from one designed alongside the code that should have absorbed it.
|
|
45
45
|
4. **Define architecture.** Describe the high-level structure: components, their responsibilities, and how they communicate. Say for each one whether it extends a seam found in step 3 or is new.
|
|
46
46
|
5. **Specify interfaces.** For each component boundary, define the contract (function signatures, API shapes, data types).
|
|
@@ -26,10 +26,10 @@ Read only:
|
|
|
26
26
|
- `design.md` — the sections the next task cites, not the whole document once tasks are
|
|
27
27
|
under way
|
|
28
28
|
- `requirements.md` — the acceptance criteria the next task claims
|
|
29
|
-
- the always-read guidance layers named in `.aidlc/guidance/index.yaml` (see **The always-read rule**
|
|
29
|
+
- the always-read guidance layers named in `.aidlc/guidance/index.yaml` (see **The always-read rule** (`.aidlc/resources/rules/always-read.md`))
|
|
30
30
|
- `.aidlc/context/style-guide.md`
|
|
31
31
|
|
|
32
|
-
Then the source files that task touches. See **The context rule**
|
|
32
|
+
Then the source files that task touches. See **The context rule** (`.aidlc/resources/rules/context.md`).
|
|
33
33
|
|
|
34
34
|
## Required Artifacts
|
|
35
35
|
|
|
@@ -41,7 +41,7 @@ Then the source files that task touches. See **The context rule** in **aidlc-ove
|
|
|
41
41
|
> {{glossary:gate}}
|
|
42
42
|
|
|
43
43
|
1. **Load context.** Read `.aidlc/context/style-guide.md` and `.aidlc/context/architecture.md` if they exist. Match the project's established patterns. If the project has a knowledge graph (`.aidlc/knowledge/` exists), also run `aidlc knowledge context --scope phase --phase implementation` and query it (`aidlc knowledge query <term>`) before re-exploring code it already describes — as an index into the source, never a substitute for reading it. Open the file before calling anything the graph names; an entry can outlive the symbol it describes.
|
|
44
|
-
2. **Load guidance.** Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule**
|
|
44
|
+
2. **Load guidance.** Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule** (`.aidlc/resources/rules/always-read.md`) for which layers those are and when to reach for the full `lessons.md`. Apply their rules during implementation.
|
|
45
45
|
3. **Execute the task breakdown.** When the instance has a `tasks.md` (produced in Design for full/quick-feature scope), read it and execute tasks in order: complete a task, then mark its checkbox `[x]` as part of the same work unit — never batch checkbox updates for later. A task that should not be done is deferred in place (`- [>] T<n>: <title> (deferred YYYY-MM-DD: <reason>)`) with a dated reason, never skipped silently or deleted; the implementation→testing gate blocks on open tasks. For bugfix scope, create the optional `tasks.md` at implementation start when the fix spans more than one commit-sized unit. For Micro scope, reference the task description and acceptance criteria directly — no task file.
|
|
46
46
|
4. **Write code.** Follow the design interfaces. Match existing code style (naming, formatting, error handling patterns).
|
|
47
47
|
5. **Handle sensitive operations.** Before executing any of the following, describe the action and wait for explicit user confirmation:
|
package/skills/50-testing.md
CHANGED
|
@@ -27,7 +27,7 @@ inherited. Read only:
|
|
|
27
27
|
|
|
28
28
|
Not `design.md`: the design's job ended when the code existed, and the test verifies the
|
|
29
29
|
code against the *requirements*. Not the implementation conversation.
|
|
30
|
-
See **The context rule**
|
|
30
|
+
See **The context rule** (`.aidlc/resources/rules/context.md`).
|
|
31
31
|
|
|
32
32
|
## Required Artifacts
|
|
33
33
|
|
|
@@ -41,7 +41,7 @@ See **The context rule** in **aidlc-overview**.
|
|
|
41
41
|
> {{glossary:gate}}
|
|
42
42
|
> {{glossary:artifact}}
|
|
43
43
|
|
|
44
|
-
1. **Review acceptance criteria.** Read `requirements.md` (or task description for Micro scope). Each criterion needs at least one test. Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule**
|
|
44
|
+
1. **Review acceptance criteria.** Read `requirements.md` (or task description for Micro scope). Each criterion needs at least one test. Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule** (`.aidlc/resources/rules/always-read.md`) for which layers those are and when to reach for the full `lessons.md`.
|
|
45
45
|
2. **Write automated tests.** Follow the project's existing test patterns:
|
|
46
46
|
- Unit tests for pure logic and edge cases
|
|
47
47
|
- Integration tests for component interactions
|
package/skills/60-deployment.md
CHANGED
|
@@ -37,7 +37,7 @@ Read only:
|
|
|
37
37
|
Not `requirements.md`, not `design.md`, not `code-complete.md`. The release is prepared from
|
|
38
38
|
what the *preceding phases concluded*, and each of those conclusions is already a compact
|
|
39
39
|
artifact. Read one of them only if a specific question sends you there.
|
|
40
|
-
See **The context rule**
|
|
40
|
+
See **The context rule** (`.aidlc/resources/rules/context.md`).
|
|
41
41
|
|
|
42
42
|
## Required Artifacts
|
|
43
43
|
|
|
@@ -51,7 +51,7 @@ deployment checklist.
|
|
|
51
51
|
> {{glossary:gate}}
|
|
52
52
|
> {{glossary:artifact}}
|
|
53
53
|
|
|
54
|
-
1. **Load guidance.** Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule**
|
|
54
|
+
1. **Load guidance.** Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule** (`.aidlc/resources/rules/always-read.md`) for which layers those are and when to reach for the full `lessons.md`.
|
|
55
55
|
2. **Validate readiness.** Check the phase state files: every preceding required phase must be complete (all required artifacts `complete`). If any gate fails, address the gap before proceeding. (CLI shortcut: `aidlc gate <instance> deployment` — the phase name is the second argument, not the first.)
|
|
56
56
|
3. **Write release plan.** Document in the phase's required artifact (see Required Artifacts above):
|
|
57
57
|
- What is being deployed (version, changes summary)
|
package/skills/70-maintenance.md
CHANGED
|
@@ -29,7 +29,7 @@ Read only:
|
|
|
29
29
|
- `deployment-record.md` — what shipped, and what was deferred
|
|
30
30
|
- whatever the specific maintenance question sends you to
|
|
31
31
|
|
|
32
|
-
Nothing from before deployment by default. See **The context rule**
|
|
32
|
+
Nothing from before deployment by default. See **The context rule** (`.aidlc/resources/rules/context.md`).
|
|
33
33
|
|
|
34
34
|
## Required Artifacts
|
|
35
35
|
|
|
@@ -40,7 +40,7 @@ and follow-up items.
|
|
|
40
40
|
|
|
41
41
|
## Instructions
|
|
42
42
|
|
|
43
|
-
1. **Load guidance.** Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule**
|
|
43
|
+
1. **Load guidance.** Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule** (`.aidlc/resources/rules/always-read.md`) for which layers those are and when to reach for the full `lessons.md`.
|
|
44
44
|
2. **Monitor.** Check that the deployed changes behave as expected in their target environment. Note any anomalies.
|
|
45
45
|
3. **Update documentation.** Ensure project docs reflect the new state:
|
|
46
46
|
- README or user-facing docs updated if behavior changed
|
package/skills/80-review.md
CHANGED
|
@@ -42,7 +42,7 @@ The split is also the better review. Reviewing `design.md` and `tasks.md` into o
|
|
|
42
42
|
|
|
43
43
|
1. **Read the target artifact completely.** Do not skim.
|
|
44
44
|
- When the phase requires a `tasks.md` as well as a `design.md`, review the breakdown **with the design in hand** — breakdown completeness (every design section covered by a task), task sizing (commit-sized units), and AC linkage (tasks reference the criteria they satisfy) are all judgements about the design/breakdown pair, not about `tasks.md` alone. Read both, then record the breakdown's findings in its own findings file.
|
|
45
|
-
2. **Load guidance.** Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule**
|
|
45
|
+
2. **Load guidance.** Read the always-read guidance layers from `.aidlc/guidance/index.yaml` — see **The always-read rule** (`.aidlc/resources/rules/always-read.md`) for which layers those are and when to reach for the full `lessons.md`.
|
|
46
46
|
3. **Check for installed compliance controls.** Run `aidlc compliance list`. If nothing is installed, skip this step and the compliance findings stream below entirely — there is nothing to check and no file to write. If a pack is installed, run `aidlc compliance check` to get the controls that apply to this phase, each with what it requires, where to look, and its fail condition. Apply those fail conditions **as written**: they are the pack's, and reinterpreting one turns a stated control into your opinion.
|
|
47
47
|
4. **Examine for each dimension:**
|
|
48
48
|
- **Ambiguities** — Vague terms, undefined behavior, unclear scope
|
package/skills/81-continue.md
CHANGED
|
@@ -42,7 +42,7 @@ Resume an in-progress lifecycle instance efficiently. Determine where work left
|
|
|
42
42
|
instance to a new phase, run `aidlc cost context` and report the line it prints. Crossing a
|
|
43
43
|
boundary is the one moment a fresh session is free, and the reading is what makes that
|
|
44
44
|
visible instead of leaving it to be noticed on the bill. Over budget is information, never a
|
|
45
|
-
blocker — see **The context rule**
|
|
45
|
+
blocker — see **The context rule** (`.aidlc/resources/rules/context.md`).
|
|
46
46
|
7. **Execute.** Follow the phase skill for the determined step.
|
|
47
47
|
|
|
48
48
|
## Multiple Instances
|
package/skills/83-add-skill.md
CHANGED
|
@@ -21,7 +21,7 @@ separate request made after the skill exists.
|
|
|
21
21
|
The user describes something they do **repeatedly** with the **same steps** — publishing a post,
|
|
22
22
|
rotating credentials, regenerating a report, cutting a release note.
|
|
23
23
|
|
|
24
|
-
Before generating anything, apply the rule
|
|
24
|
+
Before generating anything, apply the rule in `.aidlc/resources/rules/lifecycle-or-skill.md`: *lifecycle for changes to the
|
|
25
25
|
system; skills for repeatable operations of the system.*
|
|
26
26
|
|
|
27
27
|
## Instructions
|
|
@@ -80,7 +80,7 @@ Run only in the **primary checkout** (not a linked worktree — check `git rev-p
|
|
|
80
80
|
|
|
81
81
|
1. Propose merges of duplicate/superseded sections, retirement of stale entries, and application of `[promote-to-context]` flags (drafting the context-doc edit for approval).
|
|
82
82
|
2. **Every edit is confirmed by the user individually.** Nothing is deleted silently.
|
|
83
|
-
3. **Regenerate `lessons-digest.md`** — the always-read distillation that stands in for the full corpus (see **The always-read rule**
|
|
83
|
+
3. **Regenerate `lessons-digest.md`** — the always-read distillation that stands in for the full corpus (see **The always-read rule** (`.aidlc/resources/rules/always-read.md`)). Rewrite everything under its `## Entries` heading with the lessons this project has paid for **more than once**, each ending with `— from <instance>, <date>` as in `lessons.md`. Keep the whole file **at or under 4096 bytes**; that bound is the point of the file, so a digest that needs more entries needs shorter ones, not a larger cap. Leave the text above `## Entries` alone — it states that the digest is lossy and names the full corpus, and a reader who only has the digest depends on both.
|
|
84
84
|
4. **Confirm what the digest omits**, not only what it keeps. A digest is a lossy read of a safety mechanism: show which entries did not make it and get the same individual confirmation step 2 requires. Dropping a lesson from the always-read layer is a decision the user makes, never a side effect of fitting a byte budget.
|
|
85
85
|
5. Report what changed; set `last_consolidated` in `index.yaml` to today.
|
|
86
86
|
|