xdrs-core 0.48.0 → 0.49.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.filedist-package.yml +2 -2
- package/.xdrs/_core/adrs/index.md +9 -9
- package/.xdrs/_core/adrs/principles/001-xdrs-standards.md +5 -5
- package/.xdrs/_core/adrs/principles/002-policy-standards.md +2 -2
- package/.xdrs/_core/adrs/principles/003-skill-standards.md +11 -13
- package/.xdrs/_core/adrs/principles/004-article-standards.md +1 -1
- package/.xdrs/_core/adrs/principles/006-research-standards.md +1 -1
- package/.xdrs/_core/adrs/principles/007-initiative-standards.md +1 -1
- package/.xdrs/_core/adrs/principles/009-presentation-standards.md +1 -1
- package/.xdrs/_core/adrs/principles/018-external-path-symlinks.md +1 -1
- package/.xdrs/_core/adrs/principles/articles/.assets/001-xdrs-overview-slides.md +1 -1
- package/.xdrs/_core/adrs/principles/articles/001-xdrs-overview.md +8 -8
- package/.xdrs/_core/adrs/principles/skills/.assets/conflict-detection.md +1 -1
- package/.xdrs/_core/adrs/principles/skills/{009-compile-scope → compile-scope}/SKILL.md +2 -2
- package/.xdrs/_core/adrs/principles/skills/{001-review → review}/SKILL.md +1 -1
- package/.xdrs/_core/adrs/principles/skills/{001-review/001-review.test.int.js → review/review.test.int.js} +3 -3
- package/.xdrs/_core/adrs/principles/skills/{004-write-article → write-article}/SKILL.md +3 -3
- package/.xdrs/_core/adrs/principles/skills/{004-write-article/004-write-article.test.int.js → write-article/write-article.test.int.js} +1 -1
- package/.xdrs/_core/adrs/principles/skills/{006-write-initiative → write-initiative}/SKILL.md +1 -1
- package/.xdrs/_core/adrs/principles/skills/{002-write-policy → write-policy}/SKILL.md +1 -1
- package/.xdrs/_core/adrs/principles/skills/{002-write-policy/002-write-policy.test.int.js → write-policy/write-policy.test.int.js} +2 -2
- package/.xdrs/_core/adrs/principles/skills/{007-write-presentation → write-presentation}/SKILL.md +3 -3
- package/.xdrs/_core/adrs/principles/skills/{005-write-research → write-research}/SKILL.md +3 -3
- package/.xdrs/_core/adrs/principles/skills/{005-write-research/005-write-research.test.int.js → write-research/write-research.test.int.js} +1 -1
- package/.xdrs/_core/adrs/principles/skills/{003-write-skill → write-skill}/SKILL.md +15 -19
- package/.xdrs/_core/adrs/principles/skills/{003-write-skill/003-write-skill.test.int.js → write-skill/write-skill.test.int.js} +1 -1
- package/.xdrs/_core/adrs/principles/skills/{008-write-xdrs-doc → write-xdrs-doc}/SKILL.md +7 -7
- package/.xdrs/_core/index.md +12 -10
- package/.xdrs/index.md +1 -1
- package/README.md +4 -3
- package/lib/lint.js +5 -15
- package/lib/lint.test.js +3 -3
- package/package.json +2 -2
- /package/.xdrs/_core/adrs/principles/skills/{001-review → review}/001-review.test.int.report +0 -0
- /package/.xdrs/_core/adrs/principles/skills/{004-write-article → write-article}/004-write-article.test.int.report +0 -0
- /package/.xdrs/_core/adrs/principles/skills/{002-write-policy → write-policy}/002-write-policy.test.int.report +0 -0
- /package/.xdrs/_core/adrs/principles/skills/{005-write-research → write-research}/005-write-research.test.int.report +0 -0
- /package/.xdrs/_core/adrs/principles/skills/{003-write-skill → write-skill}/003-write-skill.test.int.report +0 -0
package/.filedist-package.yml
CHANGED
|
@@ -10,9 +10,9 @@ sets:
|
|
|
10
10
|
output:
|
|
11
11
|
path: .
|
|
12
12
|
symlinks:
|
|
13
|
-
- source: .xdrs/**/skills/
|
|
13
|
+
- source: .xdrs/**/skills/review
|
|
14
14
|
target: .agents/skills
|
|
15
|
-
- source: .xdrs/**/skills/
|
|
15
|
+
- source: .xdrs/**/skills/write-xdrs-doc
|
|
16
16
|
target: .agents/skills
|
|
17
17
|
gitignore: false
|
|
18
18
|
|
|
@@ -31,15 +31,15 @@ Foundational standards, principles, and guidelines.
|
|
|
31
31
|
|
|
32
32
|
Step-by-step procedural guides for humans and AI agents.
|
|
33
33
|
|
|
34
|
-
- [
|
|
35
|
-
- [
|
|
36
|
-
- [
|
|
37
|
-
- [
|
|
38
|
-
- [
|
|
39
|
-
- [
|
|
40
|
-
- [
|
|
41
|
-
- [
|
|
42
|
-
- [
|
|
34
|
+
- [review](principles/skills/review/SKILL.md) - **Review** — review code and files against Policies
|
|
35
|
+
- [write-policy](principles/skills/write-policy/SKILL.md) - **Write Policy** — create a new Policy document
|
|
36
|
+
- [write-skill](principles/skills/write-skill/SKILL.md) - **Write Skill** — create a new skill package
|
|
37
|
+
- [write-article](principles/skills/write-article/SKILL.md) - **Write Article** — create a new article document
|
|
38
|
+
- [write-research](principles/skills/write-research/SKILL.md) - **Write Research** — create a new research document
|
|
39
|
+
- [write-initiative](principles/skills/write-initiative/SKILL.md) - **Write Initiative** — create a new initiative document
|
|
40
|
+
- [write-presentation](principles/skills/write-presentation/SKILL.md) - **Write Presentation** — create Marp slide presentations for XDRS documents
|
|
41
|
+
- [write-xdrs-doc](principles/skills/write-xdrs-doc/SKILL.md) - **Write XDRS Doc** — router skill; infers document type and delegates to the appropriate authoring skill
|
|
42
|
+
- [compile-scope](principles/skills/compile-scope/SKILL.md) - **Compile Scope** — compiles or updates a `compiled`-type scope from its configured external sources
|
|
43
43
|
|
|
44
44
|
## Articles
|
|
45
45
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: _core-adr-policy-001-xdrs-standards
|
|
3
|
-
description: Defines the core XDRS framework including types (ADR, BDR, EDR), folder structure, scopes, subjects, and index requirements. Use when structuring or navigating policies.
|
|
3
|
+
description: Defines the core XDRS (eXtensible Decision Record System) framework including types (ADR, BDR, EDR), folder structure, scopes, subjects, and index requirements. Use when structuring or navigating policies.
|
|
4
4
|
apply-to: All XDRS scopes and document types
|
|
5
5
|
valid-from: 2025-01-01
|
|
6
6
|
---
|
|
@@ -53,7 +53,7 @@ ADR and EDR share the same six technical subject names (see [`_core-adr-policy-0
|
|
|
53
53
|
- **Files listed in `.filedist.lock` are external XDRs.** A file whose path appears in the workspace root `.filedist.lock` file was distributed from an external source repository. It MUST NOT be modified locally. To change it, submit the change to the source repository and re-extract the updated package. The `.filedist.lock` format is one entry per line: `<relative-path>|<package>|<version>`. A scope is considered external when any of its files appear in `.filedist.lock`, and tools (such as `xdrs-core lint`) will skip external scopes by default. The `.filedist.lock` file can also be used to detect which files changed when bumping an external scope to a newer version: compare the version field in `.filedist.lock` entries before and after the upgrade and diff the affected paths to understand what decisions were added, updated, or removed.
|
|
54
54
|
- Optional supporting artifacts under the same subject:
|
|
55
55
|
- `[xdrs-root]/[scope]/[type]/[subject]/researches/[number]-[short-title].md`
|
|
56
|
-
- `[xdrs-root]/[scope]/[type]/[subject]/skills/[
|
|
56
|
+
- `[xdrs-root]/[scope]/[type]/[subject]/skills/[skill-name]/SKILL.md`
|
|
57
57
|
- `[xdrs-root]/[scope]/[type]/[subject]/articles/[number]-[short-title].md`
|
|
58
58
|
- `[xdrs-root]/[scope]/[type]/[subject]/initiatives/[number]-[short-title].md`
|
|
59
59
|
- Research, skills, and articles are part of the framework, but each has its own concept-specific standards in dedicated Policies. This Policy defines the shared framework baseline; `_core-adr-policy-002` defines the Policy document writing standard.
|
|
@@ -67,7 +67,7 @@ ADR and EDR share the same six technical subject names (see [`_core-adr-policy-0
|
|
|
67
67
|
- Articles use `[xdrs-root]/[scope]/[type]/[subject]/articles/.assets/`
|
|
68
68
|
- Research uses `[xdrs-root]/[scope]/[type]/[subject]/researches/.assets/`
|
|
69
69
|
- Initiatives use `[xdrs-root]/[scope]/[type]/[subject]/initiatives/.assets/`
|
|
70
|
-
- Skills use `[xdrs-root]/[scope]/[type]/[subject]/skills/[
|
|
70
|
+
- Skills use `[xdrs-root]/[scope]/[type]/[subject]/skills/[skill-name]/.assets/`
|
|
71
71
|
- **Scopes:**
|
|
72
72
|
- Short name that defines a group or a package of XDRS
|
|
73
73
|
- examples: `business-x`, `business-y`, `team-43`, `_core`
|
|
@@ -147,8 +147,8 @@ subject/
|
|
|
147
147
|
- [_core-adr-policy-010 - Scope governance](010-scope-governance.md) - Scope-type definition convention, scope-local standards, and governance application model
|
|
148
148
|
- [_core-adr-policy-011 - core scope type](011-core-scope-type.md) - Defines the `core` scope type and meta-governance scope conventions
|
|
149
149
|
- [_core-adr-policy-016 - Policy Subjects](016-policy-subjects.md) - Allowed subjects per type, descriptions, examples, and disambiguation tiebreakers
|
|
150
|
-
- [
|
|
151
|
-
- [
|
|
150
|
+
- [review skill](skills/review/SKILL.md) - Skill for reviewing code changes against Policies
|
|
151
|
+
- [write-policy skill](skills/write-policy/SKILL.md) - Skill for creating a new Policy following this standard
|
|
152
152
|
- [_core-adr-policy-003 - Skill standards](003-skill-standards.md)
|
|
153
153
|
- [_core-adr-policy-004 - Article standards](004-article-standards.md)
|
|
154
154
|
- [_core-adr-policy-006 - Research standards](006-research-standards.md)
|
|
@@ -173,8 +173,8 @@ Question: In the end, state explicitly the question that needs to be answered. E
|
|
|
173
173
|
## References
|
|
174
174
|
|
|
175
175
|
- [_core-adr-policy-001 - XDRS standards](001-xdrs-standards.md) - Framework elements: types, scopes, subjects, folder structure
|
|
176
|
-
- [
|
|
177
|
-
- [
|
|
176
|
+
- [review skill](skills/review/SKILL.md) - Skill for reviewing code changes against Policies
|
|
177
|
+
- [write-policy skill](skills/write-policy/SKILL.md) - Skill for creating a new Policy following this standard
|
|
178
178
|
- [_core-adr-policy-003 - Skill standards](003-skill-standards.md)
|
|
179
179
|
- [_core-adr-policy-004 - Article standards](004-article-standards.md)
|
|
180
180
|
- [_core-adr-policy-006 - Research standards](006-research-standards.md)
|
|
@@ -19,7 +19,7 @@ How should skills be authored, structured, and organized within a project so tha
|
|
|
19
19
|
|
|
20
20
|
**agentskills-compatible skill packages, co-located with XDRS**
|
|
21
21
|
|
|
22
|
-
Skills follow the [agentskills](https://agentskills.io/specification) open format and live inside the XDRS subject folder under a `skills/` sub-directory. Each skill occupies its own
|
|
22
|
+
Skills follow the [agentskills](https://agentskills.io/specification) open format and live inside the XDRS subject folder under a `skills/` sub-directory. Each skill occupies its own package folder named after the skill itself, without the numeric prefix used by other XDRS document types.
|
|
23
23
|
|
|
24
24
|
A skill MAY target a human operator, an AI agent, or both. Instructions MUST be written imperatively and at a level of detail that either a person or an agent can follow without additional context. This design allows a skill to start as a human-only procedure and evolve — incrementally — toward partial or full AI automation without restructuring the document.
|
|
25
25
|
|
|
@@ -61,7 +61,7 @@ Quick test:
|
|
|
61
61
|
[type]/
|
|
62
62
|
[subject]/
|
|
63
63
|
skills/
|
|
64
|
-
[
|
|
64
|
+
[skill-name]/
|
|
65
65
|
SKILL.md # required
|
|
66
66
|
scripts/ # optional: executable scripts the agent may run
|
|
67
67
|
references/ # optional: detailed reference material
|
|
@@ -69,21 +69,19 @@ Quick test:
|
|
|
69
69
|
```
|
|
70
70
|
|
|
71
71
|
Examples:
|
|
72
|
-
- `.xdrs/_core/adrs/principles/skills/
|
|
73
|
-
- `.xdrs/business-x/edrs/devops/skills/
|
|
74
|
-
- `.xdrs/_local/adrs/principles/skills/
|
|
72
|
+
- `.xdrs/_core/adrs/principles/skills/code-review/SKILL.md`
|
|
73
|
+
- `.xdrs/business-x/edrs/devops/skills/ci-pipeline-debug/SKILL.md`
|
|
74
|
+
- `.xdrs/_local/adrs/principles/skills/my-nice-skill/SKILL.md`
|
|
75
75
|
|
|
76
|
-
**Skill
|
|
76
|
+
**Skill naming**
|
|
77
77
|
|
|
78
|
-
|
|
79
|
-
- Determine the next number by checking the highest number already present in that namespace. MUST NOT reuse numbers of deleted skills.
|
|
80
|
-
- Gaps in the sequence are expected and allowed.
|
|
78
|
+
Unlike Policies, Research, Articles, and Initiatives, skill packages MUST NOT use a numeric prefix. A skill is identified by a descriptive name alone, keeping it compatible with the wider agentskills ecosystem, where clients (including this framework's own agentskills-format consumers) expect a plain descriptive identifier rather than a sequence number. Each skill name MUST be unique within its `scope/type/subject/skills/` namespace; check for an existing skill with the same name before creating a new one.
|
|
81
79
|
|
|
82
80
|
**SKILL.md format** (agentskills spec)
|
|
83
81
|
|
|
84
82
|
```
|
|
85
83
|
---
|
|
86
|
-
name: [
|
|
84
|
+
name: [skill-name] # required: matches the folder name exactly; max 64 chars
|
|
87
85
|
description: > # required: what the skill does AND when to activate it; max 1024 chars
|
|
88
86
|
Concise explanation of the skill and the situations in which an agent should load it.
|
|
89
87
|
license: <license> # optional
|
|
@@ -112,8 +110,8 @@ Known gotchas and how to handle them.
|
|
|
112
110
|
```
|
|
113
111
|
|
|
114
112
|
Rules:
|
|
115
|
-
- The `name` field MUST match the folder name exactly (e.g., `
|
|
116
|
-
- The directory name
|
|
113
|
+
- The `name` field MUST match the folder name exactly (e.g., `code-review`). This keeps skill identifiers simple and aligned with the filesystem hierarchy.
|
|
114
|
+
- The directory name and the `name:` field MUST contain only lowercase alphanumeric characters and hyphens (e.g., `code-review`), with no numeric prefix.
|
|
117
115
|
- `## Overview` SHOULD state the task objective, expected outcome, and relevant prerequisites or tools when they matter.
|
|
118
116
|
- `## Instructions` SHOULD include verification steps or acceptance criteria at the end of the task, or at the end of major phases when partial validation matters.
|
|
119
117
|
- For diagram format preferences and non-Markdown asset rules, see [`_core-adr-policy-020`](020-media-and-asset-standards.md).
|
|
@@ -127,7 +125,7 @@ Rules:
|
|
|
127
125
|
Use the [skills-ref](https://github.com/agentskills/agentskills/tree/main/skills-ref) CLI to validate before committing:
|
|
128
126
|
|
|
129
127
|
```
|
|
130
|
-
skills-ref validate .xdrs/[scope]/[type]/[subject]/skills/[
|
|
128
|
+
skills-ref validate .xdrs/[scope]/[type]/[subject]/skills/[skill-name]
|
|
131
129
|
```
|
|
132
130
|
|
|
133
131
|
## Considered Options
|
|
@@ -101,4 +101,4 @@ when referencing an information from those documents.]
|
|
|
101
101
|
- [_core-adr-policy-001 - XDRS standards](001-xdrs-standards.md)
|
|
102
102
|
- [_core-adr-policy-003 - Skill standards](003-skill-standards.md)
|
|
103
103
|
- [_core-adr-policy-006 - Research standards](006-research-standards.md)
|
|
104
|
-
- [
|
|
104
|
+
- [write-article skill](skills/write-article/SKILL.md) - Step-by-step instructions for creating a new article
|
|
@@ -136,4 +136,4 @@ Prefer tables and bullet lists for simple comparisons; for diagrams see _core-ad
|
|
|
136
136
|
- [_core-adr-policy-003 - Skill standards](003-skill-standards.md)
|
|
137
137
|
- [_core-adr-policy-004 - Article standards](004-article-standards.md)
|
|
138
138
|
- [_core-adr-policy-020 - Media and asset standards](020-media-and-asset-standards.md) - Diagram format preferences and non-Markdown asset rules
|
|
139
|
-
- [
|
|
139
|
+
- [write-research skill](skills/write-research/SKILL.md) - Step-by-step instructions for creating a research document
|
|
@@ -137,4 +137,4 @@ Due date: YYYY-MM-DD
|
|
|
137
137
|
- [_core-adr-policy-001 - XDRS standards](001-xdrs-standards.md) - Framework elements: types, scopes, subjects, folder structure
|
|
138
138
|
- [_core-adr-policy-004 - Article standards](004-article-standards.md) - Companion artifact type for synthetic views
|
|
139
139
|
- [_core-adr-policy-006 - Research standards](006-research-standards.md) - Companion artifact type for exploratory evidence
|
|
140
|
-
- [
|
|
140
|
+
- [write-initiative skill](skills/write-initiative/SKILL.md) - Step-by-step instructions for creating a new initiative
|
|
@@ -50,6 +50,6 @@ Presentations are Markdown files in Marp format, stored in the `.assets/` folder
|
|
|
50
50
|
- [_core-adr-policy-001 - XDRS standards](001-xdrs-standards.md) - Framework structure and `.assets/` placement rules
|
|
51
51
|
- [_core-adr-policy-002 - Policy standards](002-policy-standards.md) - Policy document writing rules
|
|
52
52
|
- [_core-adr-policy-004 - Article standards](004-article-standards.md) - Article standards for multi-document views
|
|
53
|
-
- [
|
|
53
|
+
- [write-presentation skill](skills/write-presentation/SKILL.md) - Skill for creating slide presentations
|
|
54
54
|
- [_core-adr-policy-020 - Media and asset standards](020-media-and-asset-standards.md) - Diagram format preferences and non-Markdown asset rules
|
|
55
55
|
- [Marp](https://marp.app/) - Markdown Presentation Ecosystem
|
|
@@ -21,7 +21,7 @@ How should XDRS files be made accessible from paths outside the `.xdrs/` root wi
|
|
|
21
21
|
|
|
22
22
|
When a file or directory inside `.xdrs/` needs to be reachable from an external path, a symlink MUST be created at the external path pointing to the canonical `.xdrs/` location. The canonical file MUST remain inside `.xdrs/`. Files MUST NOT be copied to external paths.
|
|
23
23
|
|
|
24
|
-
**Example:** `.agents/skills/
|
|
24
|
+
**Example:** `.agents/skills/review` (symlink) → `.xdrs/_core/adrs/principles/skills/review/`
|
|
25
25
|
|
|
26
26
|
### Details
|
|
27
27
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
## Overview
|
|
4
4
|
|
|
5
|
-
This article introduces XDRS, explains its purpose and design, and guides
|
|
5
|
+
This article introduces XDRS (eXtensible Decision Record System), explains its purpose and design, and guides
|
|
6
6
|
teams through adopting, extending, and distributing them. It is an entry point for anyone new to
|
|
7
7
|
the framework and links out to the authoritative Policy documents for full details.
|
|
8
8
|
|
|
@@ -114,7 +114,7 @@ Every decision record and its supporting artifacts live at a fixed path:
|
|
|
114
114
|
researches/
|
|
115
115
|
[number]-[short-title].md
|
|
116
116
|
skills/
|
|
117
|
-
[
|
|
117
|
+
[skill-name]/
|
|
118
118
|
SKILL.md
|
|
119
119
|
articles/
|
|
120
120
|
[number]-[short-title].md
|
|
@@ -170,7 +170,7 @@ Follow [_core-adr-policy-001](../001-xdrs-standards.md) and [_core-adr-policy-00
|
|
|
170
170
|
allowed subject or use `principles` if none fits (propose a new subject via a `_core` ADR).
|
|
171
171
|
- **New research** — add a `researches/[number]-[short-title].md` inside the relevant subject
|
|
172
172
|
folder, following [_core-adr-policy-006](../006-research-standards.md).
|
|
173
|
-
- **New skill** — add a `skills/[
|
|
173
|
+
- **New skill** — add a `skills/[skill-name]/SKILL.md` inside the relevant subject
|
|
174
174
|
folder, following [_core-adr-policy-003](../003-skill-standards.md).
|
|
175
175
|
- **New article** — add an `articles/[number]-[short-title].md` inside the relevant subject
|
|
176
176
|
folder, following [_core-adr-policy-004](../004-article-standards.md).
|
|
@@ -200,9 +200,9 @@ Follow [_core-adr-policy-001](../001-xdrs-standards.md) and [_core-adr-policy-00
|
|
|
200
200
|
- [_core-adr-policy-004](../004-article-standards.md) - Article standards
|
|
201
201
|
- [_core-adr-policy-006](../006-research-standards.md) - Research standards
|
|
202
202
|
- [_core-adr-policy-007](../007-initiative-standards.md) - Initiative standards
|
|
203
|
-
- [
|
|
204
|
-
- [
|
|
205
|
-
- [
|
|
206
|
-
- [
|
|
207
|
-
- [
|
|
203
|
+
- [review skill](../skills/review/SKILL.md) - Reviewing code against Policies
|
|
204
|
+
- [write-policy skill](../skills/write-policy/SKILL.md) - Writing a new Policy
|
|
205
|
+
- [write-skill skill](../skills/write-skill/SKILL.md) - Writing a new skill
|
|
206
|
+
- [write-article skill](../skills/write-article/SKILL.md) - Writing a new article
|
|
207
|
+
- [write-research skill](../skills/write-research/SKILL.md) - Writing a new research document
|
|
208
208
|
- [_core-adr-policy-005](../005-semantic-versioning-for-xdrs-packages.md) - Semantic versioning rules for XDRS packages
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
## Purpose
|
|
4
4
|
|
|
5
|
-
This module provides LLM-agent instructions for detecting semantic and structural conflicts between `#### NN-rulename` rule blocks across all governance policies loaded for a scope. It is invoked from within skills (
|
|
5
|
+
This module provides LLM-agent instructions for detecting semantic and structural conflicts between `#### NN-rulename` rule blocks across all governance policies loaded for a scope. It is invoked from within skills (review, write-policy, etc.) after all governance layers have been loaded and before any authoring or review work begins.
|
|
6
6
|
|
|
7
7
|
Lint tools enforce *structural* conflicts only (duplicate rule numbers with different content). This module handles *semantic* conflicts: two rules with different numbers that are logically incompatible.
|
|
8
8
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
2
|
+
name: compile-scope
|
|
3
3
|
description: >
|
|
4
4
|
Compiles or updates any scope declaring `scope-type: compiled` from its configured external sources. Reads compilation meta-policies to discover sources, fetches content (git clone, local copy, or web scrape), plans policy changes, migrates policies one at a time with structured format, `## Source` sections, and `**compilation-note:**` markers, then runs lint and review. Documents source inconsistencies without inventing fixes. Activate when the user asks to compile, update, sync, refresh, or recompile a compiled scope.
|
|
5
5
|
metadata:
|
|
@@ -95,7 +95,7 @@ After writing each policy:
|
|
|
95
95
|
|
|
96
96
|
### Phase 6: Review
|
|
97
97
|
|
|
98
|
-
1. Read and follow `.xdrs/_core/adrs/principles/skills/
|
|
98
|
+
1. Read and follow `.xdrs/_core/adrs/principles/skills/review/SKILL.md` fully, scoped to the compiled scope.
|
|
99
99
|
2. Apply any review notes from the meta-policy's `## Review Notes` section as additional mandatory conventions during this review.
|
|
100
100
|
3. Fix only mechanical and structural findings from the review. Do NOT invent content to resolve content-level findings.
|
|
101
101
|
4. Any review findings that require inventing or guessing content MUST be recorded as inconsistencies in Phase 7.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
2
|
+
name: review
|
|
3
3
|
description: >
|
|
4
4
|
Reviews code changes, xdrs docs or any other files against applicable Policies and reports violations as structured findings.
|
|
5
5
|
Activate this skill when the user asks to review, lint, audit, check, verify, validate, or assess any files or Policies, or when checking whether a document or implementation is consistent with, compliant with, or conforms to a standard or Policy.
|
|
@@ -15,7 +15,7 @@ test('smoke test', async () => {
|
|
|
15
15
|
...copilotCmd(REPO_ROOT),
|
|
16
16
|
},
|
|
17
17
|
'Reply ONLY with "READY" after checking if SKILL 001 has any contents',
|
|
18
|
-
'Verify that the final output is ONLY "READY" and that it read file
|
|
18
|
+
'Verify that the final output is ONLY "READY" and that it read file review/SKILL.md',
|
|
19
19
|
null,
|
|
20
20
|
true
|
|
21
21
|
);
|
|
@@ -23,7 +23,7 @@ test('smoke test', async () => {
|
|
|
23
23
|
expect(err).toBe('');
|
|
24
24
|
});
|
|
25
25
|
|
|
26
|
-
test('
|
|
26
|
+
test('review outputs the required review template', async () => {
|
|
27
27
|
const err = await testPrompt(
|
|
28
28
|
{
|
|
29
29
|
workspaceRoot: REPO_ROOT,
|
|
@@ -31,7 +31,7 @@ test('001-review outputs the required review template', async () => {
|
|
|
31
31
|
...copilotCmd(REPO_ROOT),
|
|
32
32
|
},
|
|
33
33
|
'Review XDRS Policy 001-xdrs-standards',
|
|
34
|
-
'Verify that the skill
|
|
34
|
+
'Verify that the skill review was used, contains "## Findings", and "## Summary", includes an "Outcome: PASS", and that it read file review/SKILL.md and 001-xdrs-standards.md.',
|
|
35
35
|
null,
|
|
36
36
|
true
|
|
37
37
|
);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
2
|
+
name: write-article
|
|
3
3
|
description: >
|
|
4
4
|
Creates a new article document following XDRS article standards: selects scope, type, subject, and number; then writes a focused synthetic text that combines and links multiple Policies, Research documents, and Skills around a topic. Activate this skill when the user asks to create, add, or write a new article, guide, or overview document within an XDRS project.
|
|
5
5
|
metadata:
|
|
@@ -47,7 +47,7 @@ Consult `001-xdrs-standards` while making each choice in this phase. The summari
|
|
|
47
47
|
**Scope** — confirmed in Phase 0. Follow the external-scope validation in `.xdrs/_core/adrs/principles/skills/.assets/scope-selection.md`.
|
|
48
48
|
|
|
49
49
|
**Type** — match the type of the XDRS elements the article primarily synthesizes (`adrs`, `bdrs`, or `edrs`).
|
|
50
|
-
If the topic spans multiple types, use `adrs`. Use the same rules as `
|
|
50
|
+
If the topic spans multiple types, use `adrs`. Use the same rules as `write-policy` Phase 2:
|
|
51
51
|
- **BDR**: business process, product policy, strategic rule, operational procedure
|
|
52
52
|
- **ADR**: system context, integration pattern, overarching architectural choice
|
|
53
53
|
- **EDR**: specific tool/library, coding practice, testing strategy, project structure, pipelines
|
|
@@ -136,7 +136,7 @@ Follow the lint verification steps in `.xdrs/_core/adrs/principles/skills/.asset
|
|
|
136
136
|
## Edge Cases
|
|
137
137
|
|
|
138
138
|
- **Article vs. Policy confusion** — if the user asks for a document that makes a decision, write a Policy
|
|
139
|
-
(use the `
|
|
139
|
+
(use the `write-policy` skill), not an article.
|
|
140
140
|
- **Cross-subject topic** — place the article in `principles`, not in any single subject folder.
|
|
141
141
|
- **No existing articles folder** — create it; it is optional in the folder layout.
|
|
142
142
|
- **Conflicting information found** — note the conflict in the article and always defer to the Policy.
|
|
@@ -7,7 +7,7 @@ const REPO_ROOT = path.resolve(__dirname, '..', '..', '..', '..', '..', '..');
|
|
|
7
7
|
|
|
8
8
|
jest.setTimeout(300000);
|
|
9
9
|
|
|
10
|
-
test('
|
|
10
|
+
test('write-article creates a local principles article', async () => {
|
|
11
11
|
const err = await testPrompt(
|
|
12
12
|
{
|
|
13
13
|
workspaceRoot: REPO_ROOT,
|
package/.xdrs/_core/adrs/principles/skills/{006-write-initiative → write-initiative}/SKILL.md
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
2
|
+
name: write-initiative
|
|
3
3
|
description: >
|
|
4
4
|
Creates a new initiative document following XDRS initiative standards: selects scope, type, subject, and number;
|
|
5
5
|
then writes a focused execution initiative with problem context, proposed solution, approach, milestones, and deliverables.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
2
|
+
name: write-policy
|
|
3
3
|
description: >
|
|
4
4
|
Creates a new Policy interactively: selects type, scope, subject, and writes a focused, conflict-checked policy document.
|
|
5
5
|
Activate this skill when the user asks to create, add, or write a new Policy (ADR, BDR, or EDR).
|
|
@@ -7,7 +7,7 @@ const REPO_ROOT = path.resolve(__dirname, '..', '..', '..', '..', '..', '..');
|
|
|
7
7
|
|
|
8
8
|
jest.setTimeout(300000);
|
|
9
9
|
|
|
10
|
-
test('
|
|
10
|
+
test('write-policy creates a local EDR policy', async () => {
|
|
11
11
|
const err = await testPrompt(
|
|
12
12
|
{
|
|
13
13
|
workspaceRoot: REPO_ROOT,
|
|
@@ -15,7 +15,7 @@ test('002-write-policy creates a local EDR policy', async () => {
|
|
|
15
15
|
...copilotCmd(REPO_ROOT),
|
|
16
16
|
},
|
|
17
17
|
'Create a very small XDRS Policy deciding to use pnpm for Node.js monorepos',
|
|
18
|
-
'Verify that an XDRS Policy markdown file was created under .xdrs/_local/edrs/devops/, that it contains "## Context and Problem Statement" and "## Decision Outcome", that it read file
|
|
18
|
+
'Verify that an XDRS Policy markdown file was created under .xdrs/_local/edrs/devops/, that it contains "## Context and Problem Statement" and "## Decision Outcome", that it read file write-policy/SKILL.md and has the decision of using pnpm for Node.js monorepos.',
|
|
19
19
|
null,
|
|
20
20
|
true
|
|
21
21
|
);
|
package/.xdrs/_core/adrs/principles/skills/{007-write-presentation → write-presentation}/SKILL.md
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
2
|
+
name: write-presentation
|
|
3
3
|
description: >
|
|
4
4
|
Creates a Marp slide presentation for an existing XDRS document (policy, research, article, or initiative).
|
|
5
5
|
Activate this skill when the user asks to create slides, a presentation, or a slide deck for an XDRS document.
|
|
@@ -23,7 +23,7 @@ Identify the target scope from the parent document's path or the user's request;
|
|
|
23
23
|
1. Read `.xdrs/_core/adrs/principles/009-presentation-standards.md` in full to internalize all presentation rules.
|
|
24
24
|
2. Read `.xdrs/_core/adrs/principles/001-xdrs-standards.md` for `.assets/` placement rules and general framework structure.
|
|
25
25
|
3. Identify the parent document (policy, research, article, or initiative) that the slides will support. The parent document must already exist. If no parent document exists, inform the user that slides cannot be standalone and suggest creating the parent document first.
|
|
26
|
-
4. If the user wants slides covering content from multiple documents, check whether an article already exists that synthesizes those documents. If not, suggest creating an article first (using the
|
|
26
|
+
4. If the user wants slides covering content from multiple documents, check whether an article already exists that synthesizes those documents. If not, suggest creating an article first (using the `write-article` skill) and then creating slides for that article.
|
|
27
27
|
|
|
28
28
|
### Phase 2: Define the Presentation Scope
|
|
29
29
|
|
|
@@ -119,7 +119,7 @@ Rules:
|
|
|
119
119
|
- Policies: `[xdrs-root]/[scope]/[type]/[subject]/.assets/[slide-file].md`
|
|
120
120
|
- Articles: `[xdrs-root]/[scope]/[type]/[subject]/articles/.assets/[slide-file].md`
|
|
121
121
|
- Research: `[xdrs-root]/[scope]/[type]/[subject]/researches/.assets/[slide-file].md`
|
|
122
|
-
- Skills: `[xdrs-root]/[scope]/[type]/[subject]/skills/[
|
|
122
|
+
- Skills: `[xdrs-root]/[scope]/[type]/[subject]/skills/[skill-name]/.assets/[slide-file].md`
|
|
123
123
|
- Initiatives: `[xdrs-root]/[scope]/[type]/[subject]/initiatives/.assets/[slide-file].md`
|
|
124
124
|
2. Update the parent document with the link to the slide file.
|
|
125
125
|
3. Verify that the slide file name is <= 64 characters and lowercase.
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
2
|
+
name: write-research
|
|
3
3
|
description: >
|
|
4
4
|
Creates a new research document following XDRS research standards: selects scope, type, subject, and number;
|
|
5
5
|
then writes an IMRAD-based study with enough evidence and method detail to stand on its own as a technical paper.
|
|
@@ -42,7 +42,7 @@ Consult `001-xdrs-standards` while making each choice in this phase. The summari
|
|
|
42
42
|
|
|
43
43
|
**Scope** — confirmed in Phase 0. Follow the external-scope validation in `.xdrs/_core/adrs/principles/skills/.assets/scope-selection.md`.
|
|
44
44
|
|
|
45
|
-
**Type** — match the type of decision this research supports (`adrs`, `bdrs`, or `edrs`). Use the same rules as `
|
|
45
|
+
**Type** — match the type of decision this research supports (`adrs`, `bdrs`, or `edrs`). Use the same rules as `write-policy` Phase 2:
|
|
46
46
|
- **BDR**: business process, product policy, strategic rule, operational procedure
|
|
47
47
|
- **ADR**: system context, integration pattern, overarching architectural choice
|
|
48
48
|
- **EDR**: specific tool/library, coding practice, testing strategy, project structure, pipelines
|
|
@@ -280,7 +280,7 @@ Follow the lint verification steps in `.xdrs/_core/adrs/principles/skills/.asset
|
|
|
280
280
|
|
|
281
281
|
- [_core-adr-policy-006 - Research standards](../../006-research-standards.md)
|
|
282
282
|
- [_core-adr-policy-001 - XDRS standards](../../001-xdrs-standards.md)
|
|
283
|
-
- [
|
|
283
|
+
- [write-policy skill](../write-policy/SKILL.md)
|
|
284
284
|
|
|
285
285
|
## Constraints
|
|
286
286
|
|
|
@@ -7,7 +7,7 @@ const REPO_ROOT = path.resolve(__dirname, '..', '..', '..', '..', '..', '..');
|
|
|
7
7
|
|
|
8
8
|
jest.setTimeout(600000);
|
|
9
9
|
|
|
10
|
-
test('
|
|
10
|
+
test('write-research creates an IMRAD research document in copy mode', async () => {
|
|
11
11
|
const err = await testPrompt(
|
|
12
12
|
{
|
|
13
13
|
workspaceRoot: REPO_ROOT,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
2
|
+
name: write-skill
|
|
3
3
|
description: >
|
|
4
|
-
Creates a new skill package following XDRS skill standards: determines type, scope,
|
|
4
|
+
Creates a new skill package following XDRS skill standards: determines type, scope, and subject;
|
|
5
5
|
then writes a focused SKILL.md with correct frontmatter, phased instructions, examples, and edge cases.
|
|
6
6
|
Activate this skill when the user asks to create, add, or write a new skill, agent skill, or SKILL.md file.
|
|
7
7
|
metadata:
|
|
@@ -22,11 +22,11 @@ Guides the creation of a well-structured skill package by following `_core-adr-p
|
|
|
22
22
|
|
|
23
23
|
### Phase 1: Understand the Skill Goal
|
|
24
24
|
|
|
25
|
-
1. Read `.xdrs/_core/adrs/principles/003-skill-standards.md` in full to internalize the SKILL.md format
|
|
26
|
-
2. Read `.xdrs/_core/adrs/principles/001-xdrs-standards.md` in full before defining any core element for the skill package. Treat it as the canonical source for type, scope, subject,
|
|
25
|
+
1. Read `.xdrs/_core/adrs/principles/003-skill-standards.md` in full to internalize the SKILL.md format and folder layout.
|
|
26
|
+
2. Read `.xdrs/_core/adrs/principles/001-xdrs-standards.md` in full before defining any core element for the skill package. Treat it as the canonical source for type, scope, subject, naming constraints, and folder placement rules.
|
|
27
27
|
3. Identify what the skill must do, the concrete outcome it should produce, and the exact conditions under which an agent should activate it. Do NOT proceed without a clear goal, outcome, and activation trigger.
|
|
28
28
|
|
|
29
|
-
### Phase 2: Select Type, Scope,
|
|
29
|
+
### Phase 2: Select Type, Scope, and Subject
|
|
30
30
|
|
|
31
31
|
Consult `001-xdrs-standards` while making each choice in this phase. The summaries below are orientation only; when there is any ambiguity or edge case, the standard decides.
|
|
32
32
|
|
|
@@ -44,9 +44,7 @@ Quick test:
|
|
|
44
44
|
|
|
45
45
|
**Subject** — follow the subject selection guidance in `.xdrs/_core/adrs/principles/skills/.assets/scope-selection.md`.
|
|
46
46
|
|
|
47
|
-
**Skill
|
|
48
|
-
|
|
49
|
-
**Skill name** — `[number]-[short-kebab-case-description]`, max 64 characters total. The directory name matches the `name` field exactly.
|
|
47
|
+
**Skill name** — a short, descriptive, lowercase kebab-case name (e.g. `code-review`), max 64 characters total. The directory name matches the `name` field exactly. Check `.xdrs/[scope]/[type]/[subject]/skills/` first to avoid colliding with an existing skill name.
|
|
50
48
|
|
|
51
49
|
### Phase 3: Research Existing Skills and Related Policies
|
|
52
50
|
|
|
@@ -61,7 +59,7 @@ Use the mandatory agentskills format:
|
|
|
61
59
|
|
|
62
60
|
```
|
|
63
61
|
---
|
|
64
|
-
name: [
|
|
62
|
+
name: [skill-name]
|
|
65
63
|
description: >
|
|
66
64
|
[What the skill does AND exactly when an agent should activate it. Max 1024 chars.]
|
|
67
65
|
metadata:
|
|
@@ -100,7 +98,7 @@ Rules:
|
|
|
100
98
|
- Do not present the skill itself as policy; mandatory behavior must come from referenced Policies or other policy artifacts.
|
|
101
99
|
- When the skill depends on Policies, make the activation logic and instructions consistent with the Policy metadata so the skill does not operationalize inactive or out-of-scope decisions.
|
|
102
100
|
- For diagrams and non-Markdown assets, follow `_core-adr-policy-020`: prefer plain Markdown tables/lists first, then ASCII art for very simple cases, then Mermaid.js (sequence, state, activity, entity diagrams) for complex ones, then draw.io when Mermaid is insufficient — save as Editable Vector (File → Save As → Editable Vector) and store as `.svg` in the sibling `.assets/` folder.
|
|
103
|
-
- If `SKILL.md` genuinely needs local images or supporting files, store them in `.xdrs/[scope]/[type]/[subject]/skills/[
|
|
101
|
+
- If `SKILL.md` genuinely needs local images or supporting files, store them in `.xdrs/[scope]/[type]/[subject]/skills/[skill-name]/.assets/` and link them using a same-folder relative path (e.g., `.assets/image.png`).
|
|
104
102
|
- Use relative paths for all links; never use absolute paths starting with `/`.
|
|
105
103
|
- No emojis. Lowercase filenames. Target under 6500 words.
|
|
106
104
|
|
|
@@ -119,11 +117,11 @@ If any check fails, revise before continuing.
|
|
|
119
117
|
|
|
120
118
|
### Phase 6: Write Files
|
|
121
119
|
|
|
122
|
-
1. Create the skill file at `.xdrs/[scope]/[type]/[subject]/skills/[
|
|
123
|
-
2. Create a symlink at `.agents/skills/[
|
|
120
|
+
1. Create the skill file at `.xdrs/[scope]/[type]/[subject]/skills/[skill-name]/SKILL.md`.
|
|
121
|
+
2. Create a symlink at `.agents/skills/[skill-name]` so VS Code picks it up immediately:
|
|
124
122
|
```
|
|
125
123
|
mkdir -p .agents/skills
|
|
126
|
-
ln -s ../../.xdrs/[scope]/[type]/[subject]/skills/[
|
|
124
|
+
ln -s ../../.xdrs/[scope]/[type]/[subject]/skills/[skill-name] .agents/skills/[skill-name]
|
|
127
125
|
```
|
|
128
126
|
3. Evaluate whether the scope index at `.xdrs/[scope]/index.md` should be updated to reflect the new skill. If the scope index does not exist, create it following article standards and the scope index rules in `_core-adr-policy-001`.
|
|
129
127
|
|
|
@@ -134,7 +132,7 @@ Follow the lint verification steps in `.xdrs/_core/adrs/principles/skills/.asset
|
|
|
134
132
|
### Constraints
|
|
135
133
|
|
|
136
134
|
- MUST follow the agentskills SKILL.md format from `003-skill-standards` exactly.
|
|
137
|
-
- MUST consult `001-xdrs-standards` as the canonical source for every core element definition, especially type, scope, subject,
|
|
135
|
+
- MUST consult `001-xdrs-standards` as the canonical source for every core element definition, especially type, scope, subject, naming, and placement.
|
|
138
136
|
- MUST NOT create a skill that duplicates an existing one — extend or reference it instead.
|
|
139
137
|
- MUST keep scope `_local` unless the user explicitly states otherwise.
|
|
140
138
|
- MUST NOT create documents in external scopes (scopes whose files appear in the workspace root `.filedist.lock`).
|
|
@@ -144,15 +142,13 @@ Follow the lint verification steps in `.xdrs/_core/adrs/principles/skills/.asset
|
|
|
144
142
|
- Type: EDR (engineering workflow)
|
|
145
143
|
- Scope: `_local`
|
|
146
144
|
- Subject: `platform`
|
|
147
|
-
-
|
|
148
|
-
- Output: `.xdrs/_local/edrs/platform/skills/001-debug-ci-pipeline/SKILL.md`
|
|
145
|
+
- Output: `.xdrs/_local/edrs/platform/skills/debug-ci-pipeline/SKILL.md`
|
|
149
146
|
|
|
150
147
|
**Input**: "Create a skill to review API designs"
|
|
151
148
|
- Type: ADR (architectural evaluation)
|
|
152
149
|
- Scope: `_local`
|
|
153
150
|
- Subject: `application`
|
|
154
|
-
-
|
|
155
|
-
- Output: `.xdrs/_local/adrs/application/skills/001-review-api-design/SKILL.md`
|
|
151
|
+
- Output: `.xdrs/_local/adrs/application/skills/review-api-design/SKILL.md`
|
|
156
152
|
|
|
157
153
|
## Edge Cases
|
|
158
154
|
|
|
@@ -164,4 +160,4 @@ Follow the lint verification steps in `.xdrs/_core/adrs/principles/skills/.asset
|
|
|
164
160
|
|
|
165
161
|
- [_core-adr-policy-003 - Skill standards](../../003-skill-standards.md)
|
|
166
162
|
- [_core-adr-policy-001 - XDRS standards](../../001-xdrs-standards.md)
|
|
167
|
-
- [
|
|
163
|
+
- [write-policy skill](../write-policy/SKILL.md)
|
|
@@ -7,7 +7,7 @@ const REPO_ROOT = path.resolve(__dirname, '..', '..', '..', '..', '..', '..');
|
|
|
7
7
|
|
|
8
8
|
jest.setTimeout(300000);
|
|
9
9
|
|
|
10
|
-
test('
|
|
10
|
+
test('write-skill creates a devops skill package', async () => {
|
|
11
11
|
const err = await testPrompt(
|
|
12
12
|
{
|
|
13
13
|
workspaceRoot: REPO_ROOT,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
---
|
|
2
|
-
name:
|
|
2
|
+
name: write-xdrs-doc
|
|
3
3
|
description: >
|
|
4
4
|
Use when writing documents such as decisions, policies, skills, procedures, research, initiatives, articles, or presentations.
|
|
5
5
|
Activate this skill when the user asks to create or write any XDRS element.
|
|
@@ -36,12 +36,12 @@ Read the full content of the skill file for the inferred type, then follow all i
|
|
|
36
36
|
|
|
37
37
|
| Document type | Skill file to read and follow |
|
|
38
38
|
|---|---|
|
|
39
|
-
| Policy (ADR / BDR / EDR) | `.xdrs/_core/adrs/principles/skills/
|
|
40
|
-
| Skill | `.xdrs/_core/adrs/principles/skills/
|
|
41
|
-
| Article | `.xdrs/_core/adrs/principles/skills/
|
|
42
|
-
| Research | `.xdrs/_core/adrs/principles/skills/
|
|
43
|
-
| Initiative | `.xdrs/_core/adrs/principles/skills/
|
|
44
|
-
| Presentation | `.xdrs/_core/adrs/principles/skills/
|
|
39
|
+
| Policy (ADR / BDR / EDR) | `.xdrs/_core/adrs/principles/skills/write-policy/SKILL.md` |
|
|
40
|
+
| Skill | `.xdrs/_core/adrs/principles/skills/write-skill/SKILL.md` |
|
|
41
|
+
| Article | `.xdrs/_core/adrs/principles/skills/write-article/SKILL.md` |
|
|
42
|
+
| Research | `.xdrs/_core/adrs/principles/skills/write-research/SKILL.md` |
|
|
43
|
+
| Initiative | `.xdrs/_core/adrs/principles/skills/write-initiative/SKILL.md` |
|
|
44
|
+
| Presentation | `.xdrs/_core/adrs/principles/skills/write-presentation/SKILL.md` |
|
|
45
45
|
|
|
46
46
|
### Phase 3: Validate Mermaid Diagrams
|
|
47
47
|
|
package/.xdrs/_core/index.md
CHANGED
|
@@ -10,7 +10,7 @@ valid-from: 2025-01-01
|
|
|
10
10
|
|
|
11
11
|
## Overview
|
|
12
12
|
|
|
13
|
-
The `_core` scope defines the XDRS framework itself: how policies, skills, research, articles, and initiatives are structured, written, versioned, and discovered. This scope is aimed at engineers, architects, and business analysts who build or consume xdrs-based documentation.
|
|
13
|
+
The `_core` scope defines the XDRS (eXtensible Decision Record System) framework itself: how policies, skills, research, articles, and initiatives are structured, written, versioned, and discovered. This scope is aimed at engineers, architects, and business analysts who build or consume xdrs-based documentation.
|
|
14
14
|
|
|
15
15
|
## Content
|
|
16
16
|
|
|
@@ -61,15 +61,17 @@ Every XDRS scope declares a `scope-type` in its `index.md` YAML frontmatter. A `
|
|
|
61
61
|
|
|
62
62
|
### Available skills
|
|
63
63
|
|
|
64
|
-
The `_core` scope ships with
|
|
65
|
-
|
|
66
|
-
- **
|
|
67
|
-
- **
|
|
68
|
-
- **
|
|
69
|
-
- **
|
|
70
|
-
- **
|
|
71
|
-
- **
|
|
72
|
-
- **
|
|
64
|
+
The `_core` scope ships with nine skills that automate the most common framework operations:
|
|
65
|
+
|
|
66
|
+
- **review** reviews code and files against applicable Policies
|
|
67
|
+
- **write-policy** guides creation of a new Policy document
|
|
68
|
+
- **write-skill** guides creation of a new skill package
|
|
69
|
+
- **write-article** guides creation of a new article
|
|
70
|
+
- **write-research** guides creation of a new research document
|
|
71
|
+
- **write-initiative** guides creation of a new execution initiative
|
|
72
|
+
- **write-presentation** guides creation of Marp slide presentations
|
|
73
|
+
- **write-xdrs-doc** routes a request to the right authoring skill above based on document type
|
|
74
|
+
- **compile-scope** compiles or updates a `compiled`-type scope from its configured external sources
|
|
73
75
|
|
|
74
76
|
### Getting started
|
|
75
77
|
|
package/.xdrs/index.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# XDRS Index
|
|
2
2
|
|
|
3
|
-
This index points to all type- and scope-specific XDRS indexes. It covers Architectural (ADR), Business (BDR), and Engineering (EDR) contents. Each scope has its own canonical index that lists all Policies, Skills, Articles and Initiatives for that scope, organized by subject.
|
|
3
|
+
This index points to all type- and scope-specific XDRS (eXtensible Decision Record System) indexes. It covers Architectural (ADR), Business (BDR), and Engineering (EDR) contents. Each scope has its own canonical index that lists all Policies, Skills, Articles and Initiatives for that scope, organized by subject.
|
|
4
4
|
|
|
5
5
|
## Scope Indexes
|
|
6
6
|
|
package/README.md
CHANGED
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
# xdrs-core
|
|
2
2
|
|
|
3
|
+
**XDRS — eXtensible Decision Record System**
|
|
4
|
+
|
|
3
5
|
XDRS is a framework to structure, compile and distribute Architectural (ADR), Business (BDR), and Engineering (EDR) decision records contents so that AI agents and humans can reliably find and use them with hierarchical scopes and controlled rollout in the format of distributable versioned packages. Decision Records are decomposed into Research (why), Policies (what), Skills (how), Initiative (when) and Articles (views) with a well structured index structure and the definition of hierarchical scopes.
|
|
4
6
|
|
|
5
7
|
After preparation those elements can be downloaded anywhere and used to compose xdrs corpus, which can be used as a context source for AI agents, web site publishing, RAG applications etc.
|
|
@@ -83,7 +85,7 @@ Every scope declares a `scope-type` in its `index.md` frontmatter. The six built
|
|
|
83
85
|
|
|
84
86
|
**`platform` scopes** document what already exists and is ready to use. A scope is of type `platform` when its content describes a live operational capability — what is available, how to access it, and what constraints apply.
|
|
85
87
|
|
|
86
|
-
**`compiled` scopes** hold policies compiled directly from external authoritative sources. All content must trace back to the source; no invented content is allowed. A `compiled` scope requires a local meta-policy with source URLs and compilation configuration, and uses the `
|
|
88
|
+
**`compiled` scopes** hold policies compiled directly from external authoritative sources. All content must trace back to the source; no invented content is allowed. A `compiled` scope requires a local meta-policy with source URLs and compilation configuration, and uses the `compile-scope` skill to fetch, compile, and keep content up to date. The `compiled` type may be combined with another type (e.g. `scope-type: compiled, reference`) when the combined type's governance also applies.
|
|
87
89
|
|
|
88
90
|
```yaml
|
|
89
91
|
# .xdrs/owasp-top10/adrs/principles/001-core.md (compilation meta-policy)
|
|
@@ -161,7 +163,7 @@ This is especially important for BDRs: because business rules govern decisions t
|
|
|
161
163
|
[number]-[short-title].md
|
|
162
164
|
.assets/
|
|
163
165
|
skills/ # optional skill packages for humans and AI agents
|
|
164
|
-
[
|
|
166
|
+
[skill-name]/
|
|
165
167
|
SKILL.md
|
|
166
168
|
.assets/
|
|
167
169
|
articles/ # optional synthetic views over Policies, Research, and Skills
|
|
@@ -229,7 +231,6 @@ The `lint` command reads `./.xdrs/**` from the given workspace path and checks c
|
|
|
229
231
|
|
|
230
232
|
- allowed scope, type, and subject folder structure
|
|
231
233
|
- Policy numbering uniqueness per `scope/type`
|
|
232
|
-
- skill numbering uniqueness per `scope/type/subject/skills`
|
|
233
234
|
- article numbering uniqueness per `scope/type/subject/articles`
|
|
234
235
|
- research numbering uniqueness per `scope/type/subject/researches`
|
|
235
236
|
- initiative numbering uniqueness per `scope/type/subject/initiatives`
|
package/lib/lint.js
CHANGED
|
@@ -19,7 +19,8 @@ const ALLOWED_SUBJECTS = {
|
|
|
19
19
|
const TYPE_NAMES = new Set(Object.keys(TYPE_TO_ID));
|
|
20
20
|
const RESERVED_SCOPES = new Set(['_core', '_local']);
|
|
21
21
|
const NUMBERED_FILE_RE = /^(\d{3,})-([a-z0-9-]+)\.md$/;
|
|
22
|
-
|
|
22
|
+
// Skill package folders are not numbered (see _core-adr-policy-003): plain lowercase kebab-case.
|
|
23
|
+
const SKILL_DIR_RE = /^[a-z0-9-]+$/;
|
|
23
24
|
const REQUIRED_ROOT_INDEX_TEXT = 'XDRS scopes listed last override the ones listed first';
|
|
24
25
|
const SUBJECT_ARTIFACT_DIRS = new Set(['skills', 'articles', 'researches', 'initiatives']);
|
|
25
26
|
const RESOURCE_DIR_NAME = '.assets';
|
|
@@ -1010,7 +1011,6 @@ function lintXdrsElementFrontmatter(content, expectedName, filePath, errors, war
|
|
|
1010
1011
|
|
|
1011
1012
|
function lintSkillsDirectory(xdrsRoot, scopeName, typeName, subjectName, skillsPath, errors, externalScopes = new Set()) {
|
|
1012
1013
|
const artifacts = [];
|
|
1013
|
-
const skillNumbers = new Map();
|
|
1014
1014
|
const entries = safeReadDir(skillsPath, errors, `read skills directory ${scopeName}/${typeName}/${subjectName}/skills`);
|
|
1015
1015
|
|
|
1016
1016
|
for (const entry of entries) {
|
|
@@ -1025,20 +1025,11 @@ function lintSkillsDirectory(xdrsRoot, scopeName, typeName, subjectName, skillsP
|
|
|
1025
1025
|
continue;
|
|
1026
1026
|
}
|
|
1027
1027
|
|
|
1028
|
-
|
|
1029
|
-
if (!match) {
|
|
1028
|
+
if (!SKILL_DIR_RE.test(entry.name)) {
|
|
1030
1029
|
errors.push(`Invalid skill package name: ${toDisplayPath(entryPath)} [_core-adr-policy-003]`);
|
|
1031
1030
|
continue;
|
|
1032
1031
|
}
|
|
1033
1032
|
|
|
1034
|
-
const number = match[1];
|
|
1035
|
-
const previous = skillNumbers.get(number);
|
|
1036
|
-
if (previous) {
|
|
1037
|
-
errors.push(`Duplicate skill number ${number} in ${scopeName}/${typeName}/${subjectName}/skills: ${toDisplayPath(previous)} and ${toDisplayPath(entryPath)} [_core-adr-policy-003]`);
|
|
1038
|
-
} else {
|
|
1039
|
-
skillNumbers.set(number, entryPath);
|
|
1040
|
-
}
|
|
1041
|
-
|
|
1042
1033
|
if (entry.name !== entry.name.toLowerCase()) {
|
|
1043
1034
|
errors.push(`Skill package name must be lowercase: ${toDisplayPath(entryPath)} [_core-adr-policy-003]`);
|
|
1044
1035
|
}
|
|
@@ -1076,9 +1067,8 @@ function lintSkillsDirectory(xdrsRoot, scopeName, typeName, subjectName, skillsP
|
|
|
1076
1067
|
if (!skillFm.name) {
|
|
1077
1068
|
errors.push(`SKILL.md frontmatter must include a non-empty name field: ${toDisplayPath(skillFilePath)} [_core-adr-policy-003]`);
|
|
1078
1069
|
} else {
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
errors.push(`Skill frontmatter name must be "${expectedSkillName}": ${toDisplayPath(skillFilePath)} [_core-adr-policy-003]`);
|
|
1070
|
+
if (skillFm.name !== entry.name) {
|
|
1071
|
+
errors.push(`Skill frontmatter name must be "${entry.name}": ${toDisplayPath(skillFilePath)} [_core-adr-policy-003]`);
|
|
1082
1072
|
}
|
|
1083
1073
|
if (skillFm.name.length > 64) {
|
|
1084
1074
|
errors.push(`SKILL.md frontmatter name must be 64 characters or fewer: ${toDisplayPath(skillFilePath)} [_core-adr-policy-003]`);
|
package/lib/lint.test.js
CHANGED
|
@@ -487,11 +487,11 @@ test('allows child directory relative non-asset links in XDRS element documents'
|
|
|
487
487
|
'.xdrs/_local/adrs/index.md': localAdrIndex([
|
|
488
488
|
'- [001-main](principles/001-main.md) - Main decision'
|
|
489
489
|
]),
|
|
490
|
-
'.xdrs/_local/adrs/principles/001-main.md': xdrDocument('See [skill](skills/
|
|
490
|
+
'.xdrs/_local/adrs/principles/001-main.md': xdrDocument('See [skill](skills/sample-skill/SKILL.md).'),
|
|
491
491
|
});
|
|
492
|
-
const skillDir = path.join(workspaceRoot, '.xdrs/_local/adrs/principles/skills/
|
|
492
|
+
const skillDir = path.join(workspaceRoot, '.xdrs/_local/adrs/principles/skills/sample-skill');
|
|
493
493
|
fs.mkdirSync(skillDir, { recursive: true });
|
|
494
|
-
fs.writeFileSync(path.join(skillDir, 'SKILL.md'), '---\nname:
|
|
494
|
+
fs.writeFileSync(path.join(skillDir, 'SKILL.md'), '---\nname: sample-skill\ndescription: test skill\n---\n# Skill');
|
|
495
495
|
|
|
496
496
|
const result = lintWorkspace(workspaceRoot);
|
|
497
497
|
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "xdrs-core",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "
|
|
3
|
+
"version": "0.49.0",
|
|
4
|
+
"description": "XDRS (eXtensible Decision Record System): a framework to structure, compile and distribute Architectural (ADR), Business (BDR), and Engineering (EDR) decision records contents so that AI agents and humans can reliably find and use them with hierarchical scopes and controlled rollout in the format of distributable versioned packages.",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
7
7
|
"url": "git+https://github.com/flaviostutz/xdrs-core.git"
|
/package/.xdrs/_core/adrs/principles/skills/{001-review → review}/001-review.test.int.report
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|