xdrs-core 0.7.1 → 0.9.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.
@@ -12,6 +12,13 @@ Foundational standards, principles, and guidelines.
12
12
  - [_core-adr-003](principles/003-skill-standards.md) - **Skill standards**
13
13
  - [_core-adr-004](principles/004-article-standards.md) - **Article standards**
14
14
  - [_core-adr-005](principles/005-semantic-versioning-for-xdr-packages.md) - **Semantic versioning for XDR packages**
15
+ - [_core-adr-006](principles/006-research-standards.md) - **Research standards**
16
+
17
+ ## Research
18
+
19
+ Exploratory documents that back decisions during their lifecycle.
20
+
21
+ - [_core-research-001](principles/researches/001-research-and-decision-lifecycle.md) - **Research and decision lifecycle** (how research supports XDRs, skills, and articles)
15
22
 
16
23
  ## Skills
17
24
 
@@ -21,9 +28,10 @@ Step-by-step procedural guides for humans and AI agents.
21
28
  - [002-write-xdr](principles/skills/002-write-xdr/SKILL.md) - **Write XDR** — create a new Decision Record
22
29
  - [003-write-skill](principles/skills/003-write-skill/SKILL.md) - **Write Skill** — create a new skill package
23
30
  - [004-write-article](principles/skills/004-write-article/SKILL.md) - **Write Article** — create a new article document
31
+ - [005-write-research](principles/skills/005-write-research/SKILL.md) - **Write Research** — create a new research document
24
32
 
25
33
  ## Articles
26
34
 
27
- Synthetic views combining XDRs and Skills around a specific topic.
35
+ Synthetic views combining XDRs, Research, and Skills around a specific topic.
28
36
 
29
37
  - [_core-article-001](principles/articles/001-xdrs-overview.md) - **XDRs Overview** (objective, structure, getting started, guidelines, extension, usage)
@@ -22,11 +22,27 @@ Provides clear ownership by scope, predictable navigation, and reusable decision
22
22
  ### Implementation Details
23
23
 
24
24
  - XDRs MUST contain a clear decision about a certain problem or situation. Avoid being too verbose and focus on explaining clearly the context and the decision. Avoid adding contents that are not original. If you have other references that are important to understand the document, add links and references.
25
+ - XDRs are the central artifact of the framework and the authoritative policy for their scope, type, and subject. Supporting artifacts may explain, justify, or operationalize the decision, but they do not replace it.
26
+ - XDRs MAY include a `## Metadata` section, but only when at least one supported metadata field is present. When used, `## Metadata` MUST appear immediately before `## Context and Problem Statement`.
27
+ - Supported XDR metadata fields are:
28
+ - `Applied to:` Optional. A short description of the contexts in which the decision is applicable. Keep it under 40 words. If omitted, the decision should be interpreted as applying to all logically applicable elements according to the decision text itself. Examples: `Only frontend code`, `JavaScript projects`, `Performance-sensitive codebases`
29
+ - `Validity:` Optional. Defines when the decision is active. Use ISO dates only: `from YYYY-MM-DD`, `until YYYY-MM-DD`, or `from YYYY-MM-DD until YYYY-MM-DD`. If `from` is omitted, the decision takes effect immediately. If `until` is omitted, the decision remains valid indefinitely. `Draft` or `Retired` mean the XDR should be ignored as an active rule or policy.
30
+ - Research documents MAY be added under the same subject to capture the exploration, findings, and proposals that backed a decision. Research is useful during elaboration, discussion, approval, retirement, and updates, but the XDR remains the source of truth.
25
31
  - Make it clear if an instruction is mandatory or advisory
26
32
  - Mandatory language: "must", "always", "never", "required", "mandatory"
27
33
  - Advisory language: "should", "recommended", "advised", "preferably", "possibly", "optionally"
28
34
  - Always the following folder structure:
29
35
  `.xdrs/[scope]/[type]/[subject]/[number]-[short-title].md`
36
+ - Optional supporting artifacts under the same subject:
37
+ - `.xdrs/[scope]/[type]/[subject]/researches/[number]-[short-title].md`
38
+ - `.xdrs/[scope]/[type]/[subject]/skills/[number]-[skill-name]/SKILL.md`
39
+ - `.xdrs/[scope]/[type]/[subject]/articles/[number]-[short-title].md`
40
+ - For simple structure, flow, layout, or relationship indications, documents SHOULD prefer plain Markdown, tables, or ASCII art instead of external assets.
41
+ - Images and other supporting files SHOULD be used only when they are materially necessary to preserve clarity, fidelity, or evidence. When used, they SHOULD live in a sibling `assets/` folder next to the document.
42
+ - XDRs in the subject root use `.xdrs/[scope]/[type]/[subject]/assets/`
43
+ - Articles use `.xdrs/[scope]/[type]/[subject]/articles/assets/`
44
+ - Research uses `.xdrs/[scope]/[type]/[subject]/researches/assets/`
45
+ - Skills use `.xdrs/[scope]/[type]/[subject]/skills/[number]-[skill-name]/assets/`
30
46
  - **Scopes:**
31
47
  - examples: `business-x`, `business-y`, `team-43`, `_core`
32
48
  - `_local` is a reserved scope for XDRs created locally to a specific project or repository. XDRs in `_local` must not be shared with or propagated to other contexts. This scope must always be placed in the lowest position in `.xdrs/index.md` so that its decisions override or extend any decisions from all higher-positioned scopes.
@@ -40,6 +56,9 @@ Provides clear ownership by scope, predictable navigation, and reusable decision
40
56
  - Types in IDs: `adr`, `bdr`, `edr`
41
57
  - Define the next number of an XDR by checking what is the highest number present in the type+scope. Don't fill numbering gaps, as they might be old deleted XDRs and we should never reuse numbers of different documents/decisions. Numbering gaps are expected.
42
58
  - Decisions MUST be concise and reference other XDRs to avoid duplication
59
+ - The `### Implementation Details` section SHOULD state relevant boundaries or exceptions and what a reader should do or avoid in common cases. Use `## Metadata` for short applicability or lifecycle markers and keep nuanced boundaries in the decision text.
60
+ - Use concise rules, examples, or `Do` / `Don't` lists only when they help a reader apply the decision correctly. Keep them short and decision-specific.
61
+ - When research exists for a decision, the XDR SHOULD mention the related research documents after the `## Considered Options` list.
43
62
  - Never use emojis in contents
44
63
  - Always use file names with lowercase
45
64
  - Avoid using lengthy instructions on the XDR. If there are long and detailed instructions related to the XDR, or instructions that are outside the decision, create another file with a guide. If the guide is small, keep it in the XDR itself.
@@ -64,6 +83,12 @@ All XDRs MUST follow this template
64
83
  ```markdown
65
84
  # [scope]-[type]-[number]: [Short Title]
66
85
 
86
+ ## Metadata
87
+
88
+ [Optional section. Omit the entire section when neither `Applied to:` nor `Validity:` is defined.]
89
+ Applied to: [Optional short applicability scope, under 40 words]
90
+ Validity: [Optional. Use `Draft`, `Retired`, `from YYYY-MM-DD`, `until YYYY-MM-DD`, or `from YYYY-MM-DD until YYYY-MM-DD`]
91
+
67
92
  ## Context and Problem Statement
68
93
 
69
94
  [Describe the context, background, or need that led to this decision.
@@ -80,7 +105,7 @@ Question: In the end, state explicitly the question that needs to be answered. E
80
105
 
81
106
  ### Implementation Details
82
107
 
83
- [Optional section with implementation specifics, rules, examples or impact. This is the answer to the question in the "Context and Problem Statement". (<100 lines)]
108
+ [Optional section with implementation specifics, applicability boundaries, rules, concise examples, or do/don't guidance. This is the answer to the question in the "Context and Problem Statement". (<100 lines)]
84
109
 
85
110
  ## Considered Options
86
111
 
@@ -92,6 +117,9 @@ Question: In the end, state explicitly the question that needs to be answered. E
92
117
  * Reason: Brief description of why this option was accepted, containing the strengths, strategical motivations and it's differential over the other options.
93
118
  * (REJECTED) **Option 3** - [same as above, if we have more than 2 options to choose from]
94
119
 
120
+ [Related research, if any]
121
+ - [Research document title](researches/001-example.md) - Brief description of what it informed
122
+
95
123
  ## Conflicts
96
124
 
97
125
  [If this XDR has conflicts with other scopes, this section is MANDATORY and needs to have an explanation why the conflict is accepted]
@@ -112,20 +140,32 @@ Question: In the end, state explicitly the question that needs to be answered. E
112
140
  - `.xdrs/business-x/edrs/devops/003-required-development-workflow.md`
113
141
  - `.xdrs/business-x/adrs/governance/010-security-and-secrets-management.md`
114
142
  - `.xdrs/_core/adrs/devops/001-multi-repo.md`
143
+ - Metadata examples:
144
+ - `Applied to: JavaScript projects`
145
+ - `Validity: Draft`
146
+ - `Validity: from 2026-03-01 until 2026-12-31`
147
+
148
+ ```text
149
+ subject/
150
+ |-- 001-xdr.md
151
+ |-- assets/
152
+ |-- articles/
153
+ | |-- 001-article.md
154
+ | `-- assets/
155
+ |-- researches/
156
+ | |-- 001-study.md
157
+ | `-- assets/
158
+ `-- skills/
159
+ `-- 001-task/
160
+ |-- SKILL.md
161
+ `-- assets/
162
+ ```
115
163
 
116
164
  **XDR ID Examples:**
117
165
  - `business-x-adr-001` (not `ADR-business-x-001` or `business-x-adr-1`)
118
166
  - `business-x-edr-042` (not `EDR-BUSINESS-X-042`)
119
167
  - `business-x-bdr-007`
120
168
 
121
- ## Procedures
122
-
123
- 1. Choose the correct type (ADR, BDR, EDR), scope, and subject for each new XDR.
124
- 2. Create the XDR using the template in the Implementation Details section above, adapting it for the chosen type and required sections.
125
- 3. Update or create the scope `README.md` with examples if needed.
126
- 4. Add/update the new/updated XDRs to `.xdrs/[scope]/[type]/index.md` and to the main `.xdrs/index.md`
127
- 5. Keep decision texts short and link to other XDRs for shared rules
128
-
129
169
  ## Considered Options
130
170
 
131
171
  * (REJECTED) **Flat list of decisions** - Simple but becomes unmanageable as the number grows.
@@ -138,5 +178,7 @@ Question: In the end, state explicitly the question that needs to be answered. E
138
178
  ## References
139
179
 
140
180
  - [001-lint skill](skills/001-lint/SKILL.md) - Skill for reviewing code changes against XDRs
181
+ - [002-write-xdr skill](skills/002-write-xdr/SKILL.md) - Skill for creating a new XDR from this standard
141
182
  - [_core-adr-003 - Skill standards](003-skill-standards.md)
142
183
  - [_core-adr-004 - Article standards](004-article-standards.md)
184
+ - [_core-adr-006 - Research standards](006-research-standards.md)
@@ -26,9 +26,12 @@ Skills exist on a spectrum from fully manual (human-only) to fully automated (ag
26
26
 
27
27
  Write instructions so that each step is unambiguous and self-contained. Avoid implicit knowledge that only a human or only an AI would have.
28
28
 
29
- **Relation with XDRs and Articles**
30
- Skills are procedures, XDRs are guardrails and decisions, and Articles are synthetic views that combine information from multiple XDRs and Skills.
31
- Always create links back and forth between skills <-> XDRs as a reference.
29
+ **Relation with XDRs, Research, and Articles**
30
+ Skills are procedures, XDRs are guardrails and decisions, Research documents capture the explored option space and findings behind a decision, and Articles are synthetic views that combine information from multiple artifacts.
31
+ Always create links back and forth between skills <-> XDRs when the relationship is direct, and link to related Research or Articles when they provide important context.
32
+ - Skills are task-based artifacts. They should have a clear starting trigger, an expected end result, and enough detail for a human or agent to verify that the task finished correctly.
33
+ - A skill is not policy by itself. If following a skill is mandatory, that obligation must come from an XDR or another explicit policy that references the skill.
34
+ - Skills and XDRs have a many-to-many relationship: one skill may operationalize multiple XDRs, and one XDR may be executed through multiple skills in different contexts.
32
35
 
33
36
  Place a skill under the XDR type that matches the nature of the activity the skill performs:
34
37
  - **EDR skills** - engineering workflows, tool usage, coding procedures, implementation how-tos (e.g. how to design a webpage, how to run a CI pipeline, how to debug a service)
@@ -47,7 +50,7 @@ Quick test:
47
50
  SKILL.md # required
48
51
  scripts/ # optional: executable scripts the agent may run
49
52
  references/ # optional: detailed reference material
50
- assets/ # optional: templates, images, data files
53
+ assets/ # optional: images, templates, data files, and other local resources
51
54
  ```
52
55
 
53
56
  Examples:
@@ -95,6 +98,10 @@ Known gotchas and how to handle them.
95
98
 
96
99
  Rules:
97
100
  - The `name` field must match the parent directory name exactly (e.g., directory `001-code-review` uses `name: 001-code-review`). This preserves agentskills spec compliance while encoding the ordering number.
101
+ - `## Overview` SHOULD state the task objective, expected outcome, and relevant prerequisites or tools when they matter.
102
+ - `## 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.
103
+ - For simple structure, flow, layout, or relationship indications, `SKILL.md` SHOULD prefer plain Markdown, tables, or ASCII art instead of external assets.
104
+ - Images and other local resource files referenced from `SKILL.md` SHOULD be used only when they are materially necessary and SHOULD live in `assets/` inside the same skill package.
98
105
  - Keep `SKILL.md` under 500 lines. Move lengthy reference material to `references/`.
99
106
  - Reference other files with relative paths from the skill root.
100
107
  - Always use lowercase file names.
@@ -122,3 +129,4 @@ skills-ref validate .xdrs/[scope]/[type]/[subject]/skills/[number]-[skill-name]
122
129
  - [skills-ref validation library](https://github.com/agentskills/agentskills/tree/main/skills-ref)
123
130
  - [_core-adr-001 - XDR standards](001-xdr-standards.md)
124
131
  - [_core-adr-004 - Article standards](004-article-standards.md)
132
+ - [_core-adr-006 - Research standards](006-research-standards.md)
@@ -2,23 +2,25 @@
2
2
 
3
3
  ## Context and Problem Statement
4
4
 
5
- As the number of XDRs and Skills grows, navigating and understanding related decisions across subjects and types becomes difficult. Without a structured format for synthetic documentation, teams create ad-hoc documents that drift from the actual decisions over time.
5
+ As the number of XDRs, Research documents, and Skills grows, navigating and understanding related decisions across subjects and types becomes difficult. Without a structured format for synthetic documentation, teams create ad-hoc documents that drift from the actual decisions and supporting evidence over time.
6
6
 
7
- How should articles be structured and organized to provide useful views over XDRs and Skills without replacing them as the source of truth?
7
+ How should articles be structured and organized to provide useful views over XDRs, Research, and Skills without replacing them as the source of truth?
8
8
 
9
9
  ## Decision Outcome
10
10
 
11
11
  **Subject-level synthetic documents co-located with XDRs**
12
12
 
13
- Articles are Markdown documents placed inside a subject folder alongside decision records. Placing articles within a subject keeps them close to the decisions and skills they reference.
13
+ Articles are Markdown documents placed inside a subject folder alongside decision records. Placing articles within a subject keeps them close to the decisions, research, and skills they reference.
14
14
 
15
15
  ### Implementation Details
16
16
 
17
- - Articles are views, not decisions. They summarize and synthesize content from XDRs and Skills but are NOT the source of truth. When there is a conflict between an article and a Decision Record, the Decision Record takes precedence.
18
- - Articles must reference the XDRs and Skills they synthesize. Never duplicate decision content; link back to the authoritative sources.
19
- - Articles may serve as indexes, combining related DRs and Skills on a specific topic into a single navigable document.
20
- - Articles must remain consistent with the XDRs and Skills they reference. When a referenced XDR or Skill changes, the article must be reviewed and updated.
17
+ - Articles are views, not decisions. They summarize and synthesize content from XDRs, Research, and Skills but are NOT the source of truth. When there is a conflict between an article and a Decision Record, the Decision Record takes precedence.
18
+ - Articles must reference the XDRs, Research documents, and Skills they synthesize. Never duplicate decision content; link back to the authoritative sources.
19
+ - Articles may serve as indexes, combining related artifacts on a specific topic into a single navigable document.
20
+ - Articles must remain consistent with the XDRs, Research documents, and Skills they reference. When a referenced artifact changes, the article must be reviewed and updated.
21
21
  - Place an article in the subject folder that best matches its topic. If an article spans more than one subject, place it in `principles`.
22
+ - For simple structure, flow, layout, or relationship indications, articles SHOULD prefer plain Markdown, tables, or ASCII art instead of external assets.
23
+ - Images and other local resource files referenced by an article SHOULD be used only when they are materially necessary and SHOULD live in `articles/assets/` next to the article files.
22
24
  - Always use lowercase file names.
23
25
  - Never use emojis in article content.
24
26
  - Articles should be kept under 150 lines. Move detailed content to referenced XDRs or Skills.
@@ -29,6 +31,7 @@ Articles are Markdown documents placed inside a subject folder alongside decisio
29
31
  .xdrs/[scope]/[type]/[subject]/
30
32
  articles/
31
33
  [number]-[short-title].md
34
+ assets/
32
35
  ```
33
36
 
34
37
  Examples:
@@ -55,7 +58,7 @@ All articles MUST follow this template:
55
58
 
56
59
  ## Content
57
60
 
58
- [Synthetic text combining and explaining the topic. Use links to Decision Records and Skills
61
+ [Synthetic text combining and explaining the topic. Use links to Decision Records, Research, and Skills
59
62
  when referencing an information from those documents.]
60
63
 
61
64
  ## References
@@ -76,4 +79,5 @@ when referencing an information from those documents.]
76
79
 
77
80
  - [_core-adr-001 - XDR standards](001-xdr-standards.md)
78
81
  - [_core-adr-003 - Skill standards](003-skill-standards.md)
82
+ - [_core-adr-006 - Research standards](006-research-standards.md)
79
83
  - [004-write-article skill](skills/004-write-article/SKILL.md) - Step-by-step instructions for creating a new article
@@ -2,9 +2,9 @@
2
2
 
3
3
  ## Context and Problem Statement
4
4
 
5
- Teams consume XDR packages as reusable guidance, constraints, skills, and articles. If package versions do not reflect the real impact of a release, upgrades become risky and teams lose trust in reuse.
5
+ Teams consume XDR packages as reusable guidance, constraints, Research documents, skills, and articles. If package versions do not reflect the real impact of a release, upgrades become risky and teams lose trust in reuse.
6
6
 
7
- Question: How should semantic versioning be used when publishing or versioning a package containing XDRs, skills, and articles?
7
+ Question: How should semantic versioning be used when publishing or versioning a package containing XDRs, Research documents, skills, and articles?
8
8
 
9
9
  ## Decision Outcome
10
10
 
@@ -28,8 +28,8 @@ XDR packages must use semantic versioning so the package version communicates th
28
28
  **MINOR**
29
29
  - Use a minor bump for backward-compatible additions and new capabilities.
30
30
  - Use a minor bump for new XDRs that do not break existing guidance.
31
- - Use a minor bump for new or updated articles and skill changes that extend the package without requiring consumers to undo previous adoption work.
32
- - Typical cases: new features, new optional guidance, new articles, expanded skills, or additive non-breaking decision coverage.
31
+ - Use a minor bump for new or updated Research documents, articles, and skill changes that extend the package without requiring consumers to undo previous adoption work.
32
+ - Typical cases: new features, new optional guidance, new Research documents, new articles, expanded skills, or additive non-breaking decision coverage.
33
33
 
34
34
  **PATCH**
35
35
  - Use a patch bump for low-risk fixes and simple improvements.
@@ -43,3 +43,4 @@ XDR packages must use semantic versioning so the package version communicates th
43
43
  ## References
44
44
 
45
45
  - https://semver.org/
46
+ - [_core-adr-006 - Research standards](006-research-standards.md)
@@ -0,0 +1,127 @@
1
+ # _core-adr-006: Research standards
2
+
3
+ ## Context and Problem Statement
4
+
5
+ Teams often need more space than an XDR allows to evaluate constraints, explore options, and record findings before or after a decision changes. When that material is scattered across PR comments, docs, and chat, the reasoning behind a decision becomes hard to recover or update.
6
+
7
+ Question: How should research documents be structured and organized so they communicate an investigated problem, evidence, and conclusions clearly, while remaining traceable from related XDRs?
8
+
9
+ ## Decision Outcome
10
+
11
+ **IMRAD-based subject-level research documents co-located with XDRs**
12
+
13
+ Research documents are Markdown files placed inside a subject folder alongside decision records. They use an IMRAD-inspired paper structure adapted to company needs so teams can communicate investigated problems, methods, findings, and conclusions clearly, combine experienced professional judgment with good-enough evidence, preserve reproducibility where it matters, and revisit the work when technology, constraints, or facts change.
14
+
15
+ ### Implementation Details
16
+
17
+ - Research is evidence and exploration, not the adopted decision. When a research document and an XDR disagree, the XDR takes precedence.
18
+ - `Research` is the artifact name. `researches/` is only the folder name used alongside `skills/` and `articles/`.
19
+ - Research documents MUST live under `researches/` inside the relevant subject folder:
20
+ `.xdrs/[scope]/[type]/[subject]/researches/[number]-[short-title].md`
21
+ - Research documents SHOULD stay focused on one investigated problem, comparison, or hypothesis.
22
+ - Research documents MUST state clearly what problem or question is being investigated, the relevant system or domain context, and why the subject matters in practice.
23
+ - Research documents MUST follow this section order: `Abstract`, `Introduction`, `Methods`, `Results`, `Discussion`, `Conclusion`, `References`.
24
+ - Research uses a company-adapted IMRAD structure. It MAY include informed professional judgment and experience-based observations, but claims that affect the conclusion MUST have enough evidence to be teachable, reviewable, and useful to other colleagues.
25
+ - Research does not require full academic statistical rigor. Use good-enough evidence that supports the conclusion without demanding exhaustive proof.
26
+ - Research documents MUST read as standalone technical papers for readers who do not know the XDR process.
27
+ - Mentions of future ADRs, decision lifecycle, repository process, or artifact management SHOULD be avoided in the body unless they are materially necessary to understand the research question.
28
+ - Traceability to related XDRs, skills, articles, discussions, and external sources SHOULD live primarily in `## References` and surrounding indexes rather than in the body narrative.
29
+ - Research documents MUST describe the methods, tools, sources, and conditions with enough detail that an experienced professional could at least minimally reproduce the important parts of the study, especially the aspects that materially affected the conclusion.
30
+ - The short title portion after the research id MUST stay under 20 words.
31
+ - `## Abstract` MUST be a single paragraph under 200 words summarizing the goal, methods, results, and conclusion. It SHOULD let a quick technical reader understand the question, method, main result, and takeaway.
32
+ - `## Introduction` MUST define the problem, context, constraints, known facts, experiences, gaps, assumptions, and objectives. It SHOULD prefer plain Markdown, bullet points, tables, or ASCII art for simple explanations, and SHOULD use external visuals only when they are materially necessary to improve understanding. It MUST stay under 700 words and MUST end with `Question: [central question]?`.
33
+ - `## Methods` MUST explain how the study was conducted, including design, tools, data sources, and test conditions, with a reproducibility goal. It MUST stay under 1200 words.
34
+ - `## Results` MUST present findings, data, trends, quantitative results, produced code, and option comparisons when relevant. It SHOULD prefer tables, bullet lists, or ASCII art for simple comparisons, and SHOULD use external figures only when they are materially necessary. Keep interpretation to a minimum. It MUST stay under 1800 words.
35
+ - When different options for the same problem are being analyzed, `## Results` SHOULD include comparison tables and explicit pros and cons for each option so the trade-offs are directly inspectable.
36
+ - `## Discussion` MUST interpret the results, explain significance, trade-offs, performance considerations, limitations, and implications for technical readers. It MUST stay under 1000 words.
37
+ - `## Conclusion` MUST summarize the main findings, practical takeaway, applicability boundaries, and important open questions. It MUST stay under 400 words.
38
+ - `## References` MUST list all cited literature, websites, tutorials, documentation, discussions, or related artifacts.
39
+ - In general, research SHOULD roughly follow the proportion `Introduction : Methods : Results : Discussion ≈ 3 : 5 : 6 : 4`.
40
+ - Be strict about the goal of each section. Avoid duplicating the same material across sections and prefer clarity over rhetorical flourishes.
41
+ - Research documents SHOULD stay under 5000 words total. They MAY exceed that only when the `## Introduction` explicitly states that the study will be lengthy because a very detailed analysis is required.
42
+ - Research documents SHOULD link in `## References` to the XDRs, skills, articles, discussions, and external references relevant to the subject or that later cite the work.
43
+ - A 1:1 relationship between one research document and one decision will likely be common in practice, but it is not required.
44
+ - One research document MAY also be referenced by multiple XDRs, including a mix of ADRs, BDRs, and EDRs, when the same investigation remains relevant across several decisions.
45
+ - Images and other local resource files referenced by a research document SHOULD be used only when they are materially necessary and SHOULD live in `researches/assets/` next to the research files.
46
+ - Research file names MUST be lowercase. Never use emojis.
47
+ - A research document MAY exist before the related XDR is written, or remain after the XDR changes, as long as its status and references stay clear.
48
+
49
+ **Folder layout**
50
+
51
+ ```
52
+ .xdrs/[scope]/[type]/[subject]/
53
+ researches/
54
+ [number]-[short-title].md
55
+ assets/
56
+ ```
57
+
58
+ Examples:
59
+ - `.xdrs/_core/adrs/principles/researches/001-research-and-decision-lifecycle.md`
60
+ - `.xdrs/business-x/adrs/platform/researches/003-api-gateway-options.md`
61
+ - `.xdrs/_local/edrs/ai/researches/002-model-serving-constraints.md`
62
+
63
+ **Research numbering**
64
+
65
+ - Each research document has a number unique within its `scope/type/subject/researches/` namespace.
66
+ - Determine the next number by checking the highest number already present in that namespace.
67
+ - Never reuse numbers of deleted research documents. Gaps are expected.
68
+
69
+ **Research template**
70
+
71
+ All research documents MUST follow this template:
72
+
73
+ ```markdown
74
+ # [scope]-research-[number]: [Short Title]
75
+
76
+ ## Abstract
77
+
78
+ [Single paragraph summarizing the goal, methods, results, and conclusion. Goal: let a quick technical reader understand the question, method, main result, and takeaway. Under 200 words.]
79
+
80
+ ## Introduction
81
+
82
+ [Describe the problem, context, constraints, known facts, experiences, gaps, assumptions, and objectives.
83
+ Prefer bullets, tables, or ASCII art for simple explanations. Use external visuals only when they are materially necessary. Goal: explain the investigated problem, operating context, constraints, and why the subject matters. Under 700 words.]
84
+
85
+ Question: [Central question of the research]?
86
+
87
+ ## Methods
88
+
89
+ [Explain how the study was conducted, including design, tools, data sources, and test conditions.
90
+ Include enough detail for an experienced professional to reproduce the relevant parts. Goal: make the important parts of the study reproducible. Under 1200 words.]
91
+
92
+ ## Results
93
+
94
+ [Report findings, data, trends, quantitative results, code artifacts, and option comparisons.
95
+ Prefer tables, bullets, or ASCII art for simple comparisons. Use external figures only when they are materially necessary. If multiple options solve the same problem, add comparison tables and explicit pros and cons for each option. Focus on raw findings, not interpretation. Goal: present the raw findings with minimal interpretation. Under 1800 words.]
96
+
97
+ ## Discussion
98
+
99
+ [Interpret the results, explain significance, trade-offs, performance considerations, limitations, and implications. Goal: interpret the findings for technical readers. Keep this section technically engaged and under 1000 words.]
100
+
101
+ ## Conclusion
102
+
103
+ [Summarize the main findings, practical takeaway, applicability boundaries, and important open questions. Goal: summarize the main findings and what they mean in practice. Under 400 words.]
104
+
105
+ ## References
106
+
107
+ [A list of all cited literature, websites, tutorials, documentation, discussions, and related artifacts. Goal: make all cited sources and supporting artifacts traceable.]
108
+
109
+ - [Related XDR or artifact](relative/path.md) - Why it matters
110
+ - [Another related XDR if this research informed multiple decisions](relative/path.md) - Why it matters
111
+ ```
112
+
113
+ ## Considered Options
114
+
115
+ - Related research: [001-research-and-decision-lifecycle](researches/001-research-and-decision-lifecycle.md)
116
+
117
+ * (REJECTED) **Inline long-form analysis inside the XDR** - Put all research and decision text in one file.
118
+ * Reason: Makes XDRs too long, mixes evidence with the adopted rule set, and hurts fast retrieval by humans and AI agents.
119
+ * (CHOSEN) **IMRAD-based subject-level research beside XDRs** - Keep exploratory material beside the decisions, skills, and articles it informs, using an IMRAD-inspired structure adapted to company work.
120
+ * Reason: Preserves lifecycle context, keeps the XDR concise, gives readers a predictable structure, and raises evidence quality without demanding full academic rigor.
121
+
122
+ ## References
123
+
124
+ - [_core-adr-001 - XDR standards](001-xdr-standards.md)
125
+ - [_core-adr-003 - Skill standards](003-skill-standards.md)
126
+ - [_core-adr-004 - Article standards](004-article-standards.md)
127
+ - [005-write-research skill](skills/005-write-research/SKILL.md) - Step-by-step instructions for creating a research document
@@ -8,88 +8,111 @@ the framework and links out to the authoritative Decision Records for full detai
8
8
 
9
9
  ## Content
10
10
 
11
- ### What are XDRs?
12
-
13
- XDRs are structured Markdown documents that capture decisions made by teams. Three types exist:
14
-
15
- - **ADR (Architectural Decision Record)** — architectural and technical decisions: system context,
16
- integration patterns, overarching corporate practices.
17
- - **BDR (Business Decision Record)** business process, product strategy, compliance, and
18
- operational decisions.
19
- - **EDR (Engineering Decision Record)** engineering implementation details: library choices,
20
- tooling standards, coding practices.
21
-
22
- Collectively they are called XDRs. See [_core-adr-001](../001-xdr-standards.md) for the full
23
- definition and mandatory template.
24
-
25
- ### Objective
26
-
27
- As organizations grow, decisions accumulate across teams and domains. Without a consistent
28
- structure, AI agents cannot reliably locate the right decision for a given context, and humans
29
- struggle to maintain hundreds of documents. XDRs solve both problems by defining:
30
-
31
- - A predictable folder hierarchy that any agent can navigate.
32
- - Small, focused files (target under 100 lines) that are fast for LLMs to read.
33
- - Scope and subject grouping that limits the search space.
34
- - A root index as a single discovery entry point.
35
-
36
- ### How it works
37
-
38
- Every XDR lives at a fixed path:
11
+ ### What the central elements are
12
+
13
+ The XDR framework is built around a small set of artifact types that play different roles in the
14
+ same decision system.
15
+
16
+ - **Decision Records (XDRs)** are the authoritative decisions. They answer a concrete question and
17
+ record the adopted direction. They are the central policy artifact of the framework for the
18
+ scope and topic they cover. Three decision record types exist: **ADR** for architectural and
19
+ technical decisions, **BDR** for business and operational decisions, and **EDR** for engineering
20
+ implementation decisions. See [_core-adr-001](../001-xdr-standards.md).
21
+ - **Research** captures exploration before or around a decision: constraints, findings, options,
22
+ pros, and cons. Research supports elaboration, discussion, approval, retirement, and updates,
23
+ but it is not the final rule. A single Research document may inform multiple downstream ADRs,
24
+ BDRs, or EDRs. If Research and an XDR disagree, the XDR wins. See
25
+ [_core-adr-006](../006-research-standards.md).
26
+ - **Skills** describe how to execute work under the constraints of the decisions. They add the
27
+ procedural detail that XDRs intentionally avoid. A Skill may be used by a human, an AI agent, or
28
+ both. Skills are task-based, should end in a verifiable outcome, and are only mandatory when a
29
+ policy such as an XDR makes them mandatory. See [_core-adr-003](../003-skill-standards.md).
30
+ - **Articles** are synthetic views, like this one. They explain a topic across multiple XDRs,
31
+ Research documents, and Skills, helping readers understand the system without making new
32
+ decisions. See [_core-adr-004](../004-article-standards.md).
33
+ - **Indexes and folder structure** are the discovery layer. They do not make decisions by
34
+ themselves, but they determine how people and agents find the right artifacts, how scopes
35
+ override one another, and how a large set of decisions remains navigable.
36
+
37
+ ### How they differ
38
+
39
+ The easiest way to distinguish the central elements is by asking what job each one performs.
40
+
41
+ - **XDR**: "What did we decide?"
42
+ - **Research**: "What did we learn while evaluating options?"
43
+ - **Skill**: "How do we carry out work under this decision?"
44
+ - **Article**: "How do these artifacts fit together for a reader?"
45
+ - **Index/Scope structure**: "Where do I look, and which decision set takes precedence?"
46
+
47
+ This separation matters because mixing these jobs into one file makes the system harder to search,
48
+ harder to update, and harder for agents to apply correctly.
49
+
50
+ ### How they relate over time
51
+
52
+ The framework is easiest to understand as a lifecycle rather than a static folder tree.
53
+
54
+ 1. **Explore** — A team starts with a problem, constraints, and uncertainty. Research is the best
55
+ place to compare options, record findings, and keep tradeoffs visible. That same research may
56
+ later support more than one decision record.
57
+ 2. **Decide** — Once a direction is chosen, an XDR captures the final answer in concise,
58
+ authoritative form. The XDR should make clear when the decision applies, and may link back to
59
+ the Research that informed its considered options.
60
+ 3. **Execute** — If the decision affects daily work, a Skill explains how to apply it in practice.
61
+ The Skill operationalizes the decision without turning the XDR into a procedure manual.
62
+ 4. **Explain** — When the topic becomes broad or cross-cutting, an Article synthesizes the XDR,
63
+ Research, and Skills into a navigable explanation for humans and agents.
64
+ 5. **Distribute and override** — Canonical indexes and scope ordering make the artifacts
65
+ discoverable across teams. Broader scopes can be reused, and more specific scopes can extend or
66
+ override them.
67
+
68
+ This gives XDRs a timeline feel:
69
+
70
+ - Research usually appears before or around a decision.
71
+ - The XDR marks the adopted outcome.
72
+ - Skills appear when the decision must be executed repeatedly.
73
+ - Articles appear when the ecosystem around the decision needs explanation or onboarding support.
74
+
75
+ ### How the structure supports the model
76
+
77
+ Every decision record lives at a fixed path:
39
78
 
40
79
  ```
41
80
  .xdrs/[scope]/[type]/[subject]/[number]-[short-title].md
42
81
  ```
43
82
 
44
- **Scopes** represent ownership domains (e.g. `_core`, `business-x`, `team-43`). `_local` is
45
- reserved for project-specific decisions that must not be shared externally; it always sits last
46
- in `.xdrs/index.md` so its decisions override all others.
47
-
48
- **Types** are `adrs`, `bdrs`, or `edrs`.
49
-
50
- **Subjects** constrain the domain further (e.g. `principles`, `application`, `devops`, `finance`).
51
- See [_core-adr-001](../001-xdr-standards.md) for the full allowed subject list per type.
52
-
53
- **IDs** follow the pattern `[scope]-[type abbrev]-[number]`, e.g. `_core-adr-001`. Numbers are
54
- never reused. Gaps in the sequence indicate deleted records.
83
+ Supporting artifacts live beside it in the same subject:
55
84
 
56
- Each scope+type has a canonical `index.md` that lists all XDRs with short descriptions. A root
57
- `.xdrs/index.md` points to all canonical indexes and defines scope precedence (later scopes
58
- override earlier ones).
59
-
60
- Skills — step-by-step procedural instructions for humans and AI agents — live in `[subject]/skills/` sub-directories and are
61
- distributed alongside the XDRs they implement. A skill may start as a human-only procedure and evolve toward partial or full
62
- AI automation over time, without needing to be restructured. See [_core-adr-003](../003-skill-standards.md).
85
+ ```
86
+ researches/[number]-[short-title].md
87
+ skills/[number]-[skill-name]/SKILL.md
88
+ articles/[number]-[short-title].md
89
+ ```
63
90
 
64
- Articles like this document are synthetic views that combine XDRs and Skills for a specific
65
- topic. They never replace the Decision Records as source of truth. See
66
- [_core-adr-004](../004-article-standards.md).
91
+ - **Scopes** represent ownership domains such as `_core`, `business-x`, or `team-43`.
92
+ - **Types** are `adrs`, `bdrs`, or `edrs`.
93
+ - **Subjects** narrow the domain further, such as `principles`, `application`, or `finance`.
94
+ - **Canonical indexes** list the artifacts for each scope+type, while the root `.xdrs/index.md`
95
+ defines precedence across scopes.
67
96
 
68
- ### Why it is implemented this way
97
+ This organization keeps the authoritative decision, the supporting evidence, the implementation
98
+ guidance, and the explanatory overview close together without collapsing them into one document.
69
99
 
70
- Key design choices and their rationale:
100
+ ### Why this separation works
71
101
 
72
- - **Scoped folders over a flat list** flat lists become unmanageable at scale; scopes give
73
- clear ownership and allow selective adoption.
74
- - **Small focused files** LLMs have limited context windows; small files make token budgets
75
- predictable and keep decisions unambiguous.
76
- - **Canonical indexes** — agents read the index first to narrow the set of relevant files, rather
77
- than scanning every document.
78
- - **npm distribution** — versioned packages let teams adopt specific decision sets at a specific
79
- version without being forced to take all changes at once.
80
- - **Skills co-located with XDRs** — keeping procedural guidance next to the decisions it
81
- implements reduces drift and makes discovery straightforward for humans and agents alike.
82
- Because skills span a spectrum from fully manual to fully automated, co-location also
83
- makes it easy to see when a human procedure is ready to be promoted to an agent workflow.
102
+ - **Small focused files** keep decisions readable and agent-friendly.
103
+ - **Research beside the XDR** preserves why options were accepted or rejected.
104
+ - **Skills beside the XDR** reduce drift between decisions and execution.
105
+ - **Articles above the artifacts** help readers understand the whole topic without replacing the
106
+ source of truth.
107
+ - **Indexes and scopes** let the framework scale across teams while preserving override behavior.
84
108
 
85
109
  ### Getting started
86
110
 
87
111
  1. Create or open a project workspace.
88
112
  2. Run `npx xdrs-core` in the workspace root. This installs:
89
113
  - `AGENTS.md` — instructs AI agents to always consult XDRs.
90
- - `AGENTS.local.md` — project-specific agent instructions (editable).
91
114
  - `.xdrs/index.md` — root index (editable, `keepExisting` mode).
92
- - `_core` XDRs and skills under `.xdrs/_core/`.
115
+ - `_core` XDRs, Research documents, and skills under `.xdrs/_core/`.
93
116
  3. Start a conversation with your AI agent:
94
117
  > Create an ADR about our decision to use Python for AI projects.
95
118
 
@@ -100,6 +123,7 @@ Follow [_core-adr-001](../001-xdr-standards.md) strictly. Key rules:
100
123
  - Use **mandatory language** (`must`, `never`, `required`) for non-negotiable rules and
101
124
  **advisory language** (`should`, `recommended`) for guidance.
102
125
  - Keep XDRs under 100 lines. Move procedural detail to a co-located Skill.
126
+ - Keep exploratory option analysis in a co-located Research document instead of bloating the XDR.
103
127
  - Always update the scope+type index and the root index after adding or changing an XDR.
104
128
  - Use `_local` scope when a decision is project-specific and must not be shared.
105
129
  - Never reuse a number once it has been assigned, even if the XDR is deleted.
@@ -109,6 +133,8 @@ Follow [_core-adr-001](../001-xdr-standards.md) strictly. Key rules:
109
133
  - **New scope** — create `.xdrs/[scope]/[type]/index.md` and add it to `.xdrs/index.md`.
110
134
  - **New subject** — create the subject folder under the existing scope+type path. Add an
111
135
  allowed subject or use `principles` if none fits (propose a new subject via a `_core` ADR).
136
+ - **New research** — add a `researches/[number]-[short-title].md` inside the relevant subject
137
+ folder, following [_core-adr-006](../006-research-standards.md).
112
138
  - **New skill** — add a `skills/[number]-[skill-name]/SKILL.md` inside the relevant subject
113
139
  folder, following [_core-adr-003](../003-skill-standards.md).
114
140
  - **New article** — add an `articles/[number]-[short-title].md` inside the relevant subject
@@ -120,7 +146,7 @@ Follow [_core-adr-001](../001-xdr-standards.md) strictly. Key rules:
120
146
  `pnpm exec xdrs-core extract`) to unpack XDR files into `.xdrs/` in your workspace.
121
147
  2. **Pins and upgrades** — update the npm dependency version to pull in the latest decisions
122
148
  for a scope. The `filedist` mechanism tracks managed files in `.filedist` and keeps
123
- `AGENTS.local.md` and `.xdrs/index.md` in `keepExisting` mode so local edits are preserved.
149
+ `.xdrs/index.md` in `keepExisting` mode so local edits are preserved.
124
150
  3. **Multi-scope** — list multiple scope packages as dependencies. Edit `.xdrs/index.md` to
125
151
  add each scope's canonical index link; place more specific scopes below broader ones.
126
152
  4. **Verify** — run `npx xdrs-core check` to confirm all managed files are in sync with the
@@ -133,6 +159,8 @@ Follow [_core-adr-001](../001-xdr-standards.md) strictly. Key rules:
133
159
  - [_core-adr-001](../001-xdr-standards.md) - XDR standards and mandatory template
134
160
  - [_core-adr-003](../003-skill-standards.md) - Skill standards and co-location rules
135
161
  - [_core-adr-004](../004-article-standards.md) - Article standards
162
+ - [_core-adr-006](../006-research-standards.md) - Research standards
136
163
  - [001-lint skill](../skills/001-lint/SKILL.md) - Linting code against XDRs
137
164
  - [002-write-xdr skill](../skills/002-write-xdr/SKILL.md) - Writing a new XDR
138
165
  - [003-write-skill skill](../skills/003-write-skill/SKILL.md) - Writing a new skill
166
+ - [005-write-research skill](../skills/005-write-research/SKILL.md) - Writing a new research document