@flancer32/skill-adsm-ctx 0.3.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +27 -0
- package/README.md +44 -37
- package/bin/adsm-ctx.mjs +1 -1
- package/package.json +4 -18
- package/{skill → skills/adsm-ctx}/SKILL.md +22 -5
- package/{skill → skills/adsm-ctx}/references/agents-hierarchy.md +1 -1
- package/skills/adsm-ctx/references/context-evolution.md +55 -0
- package/{skill → skills/adsm-ctx}/references/context-lifecycle.md +28 -9
- package/{skill → skills/adsm-ctx}/references/design-questionnaire.md +14 -2
- package/{skill → skills/adsm-ctx}/references/document-projections.md +39 -21
- package/{skill → skills/adsm-ctx}/references/documentation-compression.md +6 -5
- package/{skill → skills/adsm-ctx}/references/documentation-quality-audit.md +20 -5
- package/{skill → skills/adsm-ctx}/references/orchestration-model.md +10 -7
- package/{skill → skills/adsm-ctx}/references/semantic-skins.md +3 -1
- package/{skill → skills/adsm-ctx}/references/specialized-skills.md +6 -3
- package/skills/adsm-ctx/templates/AGENTS.md +19 -0
- package/skills/adsm-ctx/templates/ctx/AGENTS.md +46 -0
- package/{skill → skills/adsm-ctx}/templates/ctx/README.md +1 -1
- package/{skill → skills/adsm-ctx}/templates/ctx/adsm.json +4 -1
- package/skills/adsm-ctx/templates/ctx/agent/AGENTS.md +32 -0
- package/skills/adsm-ctx/templates/ctx/docs/AGENTS.md +64 -0
- package/skills/adsm-ctx/templates/ctx/docs/code/testing.md +17 -0
- package/skills/adsm-ctx/templates/ctx/docs/verification/AGENTS.md +31 -0
- package/src/Init/Service.mjs +5 -26
- package/src/Shared/Constants.mjs +7 -1
- package/src/Shared/Metadata.mjs +1 -0
- package/src/Skill/Installer.mjs +3 -3
- package/src/Validate/Service.mjs +282 -105
- package/types.d.ts +0 -4
- package/migrations/README.md +0 -9
- package/skill/references/upgrade-policy.md +0 -19
- package/skill/templates/AGENTS.md +0 -120
- package/skill/templates/ai/AGENTS.md +0 -59
- package/skill/templates/ctx/AGENTS.md +0 -45
- package/skill/templates/ctx/agent/AGENTS.md +0 -36
- package/skill/templates/ctx/docs/AGENTS.md +0 -55
- package/skill/templates/ctx/docs/code/testing.md +0 -13
- package/src/Cli/Command/Design.mjs +0 -17
- package/src/Cli/Command/Upgrade.mjs +0 -19
- package/src/Design/Service.mjs +0 -36
- package/src/Upgrade/Service.mjs +0 -44
- /package/{skill/templates/work → skills/adsm-ctx/assets}/context/semantic-skin.md +0 -0
- /package/{skill/templates/work → skills/adsm-ctx/assets}/report/documentation-compression.md +0 -0
- /package/{skill/templates/work → skills/adsm-ctx/assets}/report/documentation-quality-audit.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/assets/.gitkeep +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/ai-intro.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/architecture/AGENTS.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/architecture/behavior.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/architecture/checklists.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/architecture/constraints.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/architecture/decisions.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/architecture/integration.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/architecture/overview.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/architecture/state.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/architecture/structure.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/architecture/supervision.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/code/AGENTS.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/code/overview.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/environment/AGENTS.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/environment/overview.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/filesystem.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/product/AGENTS.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/product/domain.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/product/glossary.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/product/overview.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/product/roles.md +0 -0
- /package/{skill → skills/adsm-ctx}/templates/ctx/docs/product/use-cases.md +0 -0
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
# Documentation Projections
|
|
2
2
|
|
|
3
|
-
- Path: `
|
|
4
|
-
- Changed: `
|
|
3
|
+
- Path: `skills/adsm-ctx/references/document-projections.md`
|
|
4
|
+
- Changed: `20261024`
|
|
5
5
|
|
|
6
|
-
Use this reference whenever an agent initializes, designs, validates, audits, compresses, or
|
|
6
|
+
Use this reference whenever an agent initializes, designs, validates, audits, compresses, or evolves ADSM documentation under `ctx/docs/`.
|
|
7
7
|
|
|
8
8
|
## Core Model
|
|
9
9
|
|
|
@@ -100,11 +100,11 @@ Projection drift includes:
|
|
|
100
100
|
|
|
101
101
|
Validation should report structural drift such as orphan skins.
|
|
102
102
|
|
|
103
|
-
Audit, compression, and
|
|
103
|
+
Audit, compression, and evolution work should report semantic drift when it can be evidenced from the documents.
|
|
104
104
|
|
|
105
|
-
## Documentation Levels And
|
|
105
|
+
## Documentation Levels And Verification Layer
|
|
106
106
|
|
|
107
|
-
ADSM defines
|
|
107
|
+
ADSM defines exactly four ordered declarative documentation levels under `ctx/docs/`:
|
|
108
108
|
|
|
109
109
|
```text
|
|
110
110
|
ctx/docs/product/
|
|
@@ -113,32 +113,47 @@ ctx/docs/environment/
|
|
|
113
113
|
ctx/docs/code/
|
|
114
114
|
```
|
|
115
115
|
|
|
116
|
-
Their meanings:
|
|
116
|
+
Their meanings remain:
|
|
117
117
|
|
|
118
|
-
- `product` — product meaning;
|
|
119
|
-
- `architecture` — engineering structure;
|
|
120
|
-
- `environment` — runtime and deployment
|
|
121
|
-
- `code` — implementation
|
|
118
|
+
- `product` — accepted product meaning;
|
|
119
|
+
- `architecture` — accepted engineering structure;
|
|
120
|
+
- `environment` — accepted runtime and deployment conditions;
|
|
121
|
+
- `code` — accepted implementation and engineering constraints.
|
|
122
122
|
|
|
123
|
-
|
|
123
|
+
`ctx/docs/verification/` is a mandatory cross-cutting documentation block. It relates declarations to observations of reality, but is not a fifth refinement level and does not change declaration authority.
|
|
124
124
|
|
|
125
|
-
|
|
125
|
+
Require the block in schema `0.5.0`, even when it contains only `AGENTS.md`. Its root requires `AGENTS.md`; direct categories are optional `product/`, `architecture/`, `environment/`, and `code/`. Create a category only when a durable specification exists beneath it. Do not initialize empty categories or placeholder specifications.
|
|
126
|
+
|
|
127
|
+
A verification specification has one canonical home selected by its **primary verification target**: the declaration or bounded declaration group whose truth it chiefly evaluates. It may link to secondary declarations, executable tests, monitors, environments, dependencies, and other contexts. Mechanism, test framework, source path, CI job, endpoint, reporting context, and current Responsible Context do not determine placement.
|
|
128
|
+
|
|
129
|
+
A specification should state, when relevant:
|
|
130
|
+
|
|
131
|
+
- the primary target and traceability to its declaration;
|
|
132
|
+
- the expected observable corridor;
|
|
133
|
+
- approach and acquisition mode;
|
|
134
|
+
- applicability and prerequisites;
|
|
135
|
+
- bounded interpretation, reach, and blind spots;
|
|
136
|
+
- lifecycle role and follow-up, including re-verification when required; and
|
|
137
|
+
- available access or authority for obtaining the observation.
|
|
138
|
+
|
|
139
|
+
A verification specification is durable documentation. An evidence record records an actual observation and its provenance. Operational Feedback State retains unresolved routing or continuation state. Do not confuse either operational object with a declaration or durable verification specification.
|
|
140
|
+
|
|
141
|
+
Project-specific nesting by risk area, product area, subsystem, use case, integration, or operational surface is allowed inside a primary-target category. It must preserve one canonical specification.
|
|
126
142
|
|
|
127
143
|
Valid examples:
|
|
128
144
|
|
|
129
145
|
```text
|
|
130
146
|
ctx/docs/product/domain/ingress.md
|
|
131
|
-
ctx/docs/product/domain/memory.md
|
|
132
147
|
ctx/docs/architecture/runtime/agent-execution.md
|
|
133
148
|
ctx/docs/environment/deployment/vps.md
|
|
134
149
|
ctx/docs/code/modules/orchestrator.md
|
|
150
|
+
ctx/docs/verification/product/authentication.md
|
|
151
|
+
ctx/docs/verification/architecture/boundaries/adapter-isolation.md
|
|
135
152
|
```
|
|
136
153
|
|
|
137
|
-
Flat files remain allowed when suitable.
|
|
138
|
-
|
|
139
|
-
Do not require flat prefixed names such as `domain-ingress.md` when nested directories are clearer.
|
|
154
|
+
Flat files remain allowed when suitable. Do not require flat prefixed names when nested directories are clearer.
|
|
140
155
|
|
|
141
|
-
Each of the four
|
|
156
|
+
Each of the four declarative levels should contain no more than nine direct subdirectories and nine direct ordinary files. The service-control file `AGENTS.md` and all matching `*.skin.<lang>.md` files are excluded, so an agent document and all of its skins count as one document group. This is a maintainability recommendation, not a reason to collapse meaningful structure.
|
|
142
157
|
|
|
143
158
|
When a level deliberately exceeds either value, its own `AGENTS.md` must include a `## Documentation Capacity Exception` section that explicitly records the intentional exception and its reason. Deterministic validation warns about the exceeded recommendation and reports an error when this explicit local declaration is absent.
|
|
144
159
|
|
|
@@ -187,7 +202,7 @@ Do not use `AGENTS.md` as a replacement for agent documents or skins.
|
|
|
187
202
|
|
|
188
203
|
Documentation quality audit should:
|
|
189
204
|
|
|
190
|
-
- recursively include ordinary `*.md` agent documents under the four
|
|
205
|
+
- recursively include ordinary `*.md` agent documents under the four declarative levels and under the mandatory `verification/` block;
|
|
191
206
|
- classify `*.skin.<lang>.md` files as human-facing semantic skins;
|
|
192
207
|
- detect agent/skin document groups by same basename and directory;
|
|
193
208
|
- report orphan skins;
|
|
@@ -202,6 +217,8 @@ Deterministic validation should:
|
|
|
202
217
|
- require every `*.skin.<lang>.md` file to have a paired non-skin `*.md` document and an explicit valid language marker;
|
|
203
218
|
- require an explicit valid language marker, reversible paired-base resolution, and no redundant `Agent Document` section;
|
|
204
219
|
- verify local markdown document links under `ctx/docs/**`;
|
|
220
|
+
- require `ctx/docs/verification/AGENTS.md`, accept an AGENTS-only root, and require recognized primary-target categories with at least one durable specification in every created category;
|
|
221
|
+
- keep verification category placement and evidence sufficiency as semantic audit work rather than claiming them from directory shape;
|
|
205
222
|
- warn when a documentation level contains more than nine direct directories or more than nine direct ordinary files (excluding `AGENTS.md` and paired `*.skin.<lang>.md` files), and require an explicit `Documentation Capacity Exception` in that level's `AGENTS.md`;
|
|
206
223
|
- keep ordinary agent-document shape checks minimal instead of imposing a rigid body template.
|
|
207
224
|
|
|
@@ -221,12 +238,13 @@ When compressing an agent document with a matching skin, preserve the skin's pur
|
|
|
221
238
|
|
|
222
239
|
When an agent document contains human-facing semantic framing that should be preserved independently for human supervision, recommend extracting a matching skin unless the human has not authorized that migration.
|
|
223
240
|
|
|
224
|
-
##
|
|
241
|
+
## Evolution Rules
|
|
225
242
|
|
|
226
|
-
|
|
243
|
+
Follow [the agent evolution procedure](context-evolution.md). Deterministic CLI checks do not change context or metadata. Agent evolution should:
|
|
227
244
|
|
|
228
245
|
- preserve existing agent documents and project-specific nested subdirectories;
|
|
229
246
|
- add or recommend skins only where human semantic control is clear;
|
|
230
247
|
- report orphan skins and agent/skin conflicts;
|
|
231
248
|
- avoid introducing required `README.md` files inside `ctx/docs/`;
|
|
232
249
|
- keep assets under `ctx/assets/**`.
|
|
250
|
+
- preserve primary verification target, applicability, reach, blind spots, and the distinction between specification and evidence when verification documentation is in scope.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Documentation Compression
|
|
2
2
|
|
|
3
|
-
- Path: `
|
|
4
|
-
- Changed: `
|
|
3
|
+
- Path: `skills/adsm-ctx/references/documentation-compression.md`
|
|
4
|
+
- Changed: `20261024`
|
|
5
5
|
|
|
6
6
|
Use this reference when an agent must compress an existing ADSM cognitive documentation corpus while preserving accepted project meaning.
|
|
7
7
|
|
|
@@ -16,7 +16,7 @@ Compress the project cognitive documentation corpus under `ctx/docs/`.
|
|
|
16
16
|
Follow this method:
|
|
17
17
|
|
|
18
18
|
1. Read the applicable `AGENTS.md` hierarchy from the repository root to the target documentation scope. For the default scope, this means the hierarchy from the repository root to `ctx/docs/`.
|
|
19
|
-
2. Read
|
|
19
|
+
2. Read [document-projections.md](document-projections.md) from this installed skill for agent/skin classification and projection drift rules.
|
|
20
20
|
3. Use `ctx/docs/` as the default corpus unless the human explicitly provides another scope.
|
|
21
21
|
4. Exclude operational context outside `ctx/docs/` by default, including `ctx/agent/`, workflow configuration, prompt assets, generated reports, runtime materials, and `ctx/assets/**`.
|
|
22
22
|
5. Treat ordinary `*.md` files as agent-facing operational context documents and `*.skin.<lang>.md` files as human-facing semantic skins.
|
|
@@ -28,13 +28,13 @@ Follow this method:
|
|
|
28
28
|
11. Avoid inventing, weakening, generalizing, or silently deleting project-specific knowledge.
|
|
29
29
|
12. Update `Changed` attributes for every modified context document.
|
|
30
30
|
13. Report non-editorial uncertainty and skin contradictions as human decisions instead of resolving them by rewrite.
|
|
31
|
-
14. Use
|
|
31
|
+
14. Use [the compression report template](../assets/report/documentation-compression.md) as the report structure when a file report is requested.
|
|
32
32
|
|
|
33
33
|
## Corpus Selection
|
|
34
34
|
|
|
35
35
|
The default corpus is `ctx/docs/`.
|
|
36
36
|
|
|
37
|
-
Documentation compression is intended for declarative project documentation: product, architecture, environment, code,
|
|
37
|
+
Documentation compression is intended for declarative project documentation under the four ADSM levels: product, architecture, environment, and code, plus the mandatory Verification Layer when it is in scope.
|
|
38
38
|
|
|
39
39
|
Do not include operational context outside `ctx/docs/` by default, including `ctx/agent/`, generated reports, prompt assets, workflow configuration, runtime materials, `ctx/assets/**`, or other agent-operation artifacts.
|
|
40
40
|
|
|
@@ -77,6 +77,7 @@ Safe compression may:
|
|
|
77
77
|
Safe compression preserves:
|
|
78
78
|
|
|
79
79
|
- product intent and scope;
|
|
80
|
+
- verification primary targets, applicable bounds, blind spots, and the distinction between durable specification, actual evidence, and operational feedback state;
|
|
80
81
|
- domain terms and relationships;
|
|
81
82
|
- role and authority boundaries;
|
|
82
83
|
- architecture boundaries and decisions;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Documentation Quality Audit
|
|
2
2
|
|
|
3
|
-
- Path: `
|
|
4
|
-
- Changed: `
|
|
3
|
+
- Path: `skills/adsm-ctx/references/documentation-quality-audit.md`
|
|
4
|
+
- Changed: `20261024`
|
|
5
5
|
|
|
6
6
|
Use this reference when an agent must audit an existing documentation corpus as an ADSM cognitive context.
|
|
7
7
|
|
|
@@ -16,8 +16,8 @@ Audit the documentation corpus of this project against the ADSM documentation qu
|
|
|
16
16
|
Follow this method:
|
|
17
17
|
|
|
18
18
|
1. Read the applicable `AGENTS.md` hierarchy from the repository root to `ctx/docs/`, unless the user explicitly gives another documentation scope.
|
|
19
|
-
2. Read
|
|
20
|
-
3. Identify the audit corpus under `ctx/docs/`, including nested documentation under `product/`, `architecture/`, `environment/`, and `
|
|
19
|
+
2. Read [document-projections.md](document-projections.md) from this installed skill for agent/skin classification and projection drift rules.
|
|
20
|
+
3. Identify the audit corpus under `ctx/docs/`, including nested documentation under `product/`, `architecture/`, `environment/`, `code/`, and the mandatory cross-cutting `verification/` boundary.
|
|
21
21
|
4. Classify ordinary `*.md` files as agent-facing operational context documents, `*.skin.<lang>.md` files as human-facing semantic skins, and `AGENTS.md` files as local agent routing instructions.
|
|
22
22
|
5. Build a compact documentation map that shows source-of-truth agent documents, refinement relationships, agent/skin pairs, orphan skins, projection drift, and duplicated responsibility areas.
|
|
23
23
|
6. Evaluate the corpus against the eight ADSM documentation quality criteria and the projection-specific checks below after deterministic validation is clean or warning-only.
|
|
@@ -25,7 +25,7 @@ Follow this method:
|
|
|
25
25
|
8. Report only evidence-backed findings, with file references and the violated criterion.
|
|
26
26
|
9. Separate findings that can be fixed editorially from findings that require cross-document synchronization, upstream documentation changes, projection-drift resolution, or human decisions.
|
|
27
27
|
10. Do not invent missing product facts, architecture boundaries, authority rules, workflow semantics, or implementation behavior.
|
|
28
|
-
11. Use
|
|
28
|
+
11. Use [the audit report template](../assets/report/documentation-quality-audit.md) as the report structure when a file report is requested.
|
|
29
29
|
|
|
30
30
|
## Corpus Selection
|
|
31
31
|
|
|
@@ -205,3 +205,18 @@ The audit must not:
|
|
|
205
205
|
- mark a corpus incomplete merely because it does not document out-of-scope concerns.
|
|
206
206
|
|
|
207
207
|
The audit may propose correction order and candidate edits, but it must distinguish proposals from accepted project knowledge.
|
|
208
|
+
|
|
209
|
+
## Verification Layer Review
|
|
210
|
+
|
|
211
|
+
Include mandatory `ctx/docs/verification/` in the default corpus; an AGENTS-only root contains no specifications to audit. Review it as cross-cutting specification documentation, not a fifth declarative level and not an evidence or incident archive.
|
|
212
|
+
|
|
213
|
+
Check whether each durable specification:
|
|
214
|
+
|
|
215
|
+
- names a primary verification target and links to the authoritative declaration;
|
|
216
|
+
- states an observable expectation and applicable state or prerequisites;
|
|
217
|
+
- distinguishes observation method from the declaration being evaluated;
|
|
218
|
+
- identifies reach, blind spots, and limits on the conclusion;
|
|
219
|
+
- avoids duplicated specifications for the same expectation; and
|
|
220
|
+
- distinguishes detection, localization, resolution feedback, and re-verification.
|
|
221
|
+
|
|
222
|
+
Report a human decision when supervision, acceptable uncertainty, required independence, Responsible Context routing, evidence retention, or operational feedback-state ownership is missing. Do not infer these policies from test framework, directory name, issue tracker, or a passing result.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Orchestration Model
|
|
2
2
|
|
|
3
|
-
- Path: `
|
|
4
|
-
- Changed: `
|
|
3
|
+
- Path: `skills/adsm-ctx/references/orchestration-model.md`
|
|
4
|
+
- Changed: `20261024`
|
|
5
5
|
|
|
6
6
|
This skill is a router and baseline manager.
|
|
7
7
|
|
|
@@ -11,17 +11,20 @@ It is responsible for:
|
|
|
11
11
|
- the agent/skin documentation projection model;
|
|
12
12
|
- lifecycle guidance;
|
|
13
13
|
- baseline validation;
|
|
14
|
-
-
|
|
14
|
+
- agent-driven evolution guidance and read-only Deterministic CLI checks;
|
|
15
|
+
- Verification Layer documentation lifecycle support and structural validation;
|
|
15
16
|
- the reserved boundary definition for `ctx/agent/`.
|
|
16
17
|
|
|
17
|
-
It is not responsible for inventing specialized technical or domain documentation.
|
|
18
|
+
It is not responsible for inventing specialized technical or domain documentation, executing verification, receiving signals, persisting evidence or Operational Feedback State, or coordinating distributed feedback loops.
|
|
18
19
|
|
|
19
20
|
For `ctx/agent/`, this skill may:
|
|
20
21
|
|
|
21
22
|
- install only `ctx/agent/AGENTS.md` as the boundary file;
|
|
22
|
-
-
|
|
23
|
+
- explain that this branch is part of project cognitive context while its project-specific workflows are outside the reusable ADSM baseline;
|
|
23
24
|
- preserve project-local materials that humans or agents maintain there for concrete tools or relationships.
|
|
24
25
|
|
|
26
|
+
Operational materials organize authorized work within accepted declarations in `ctx/docs/` and applicable supervision constraints. They do not independently establish product or architecture authority or override human approval and escalation requirements. Preserve existing local materials and maintain navigation against the actual filesystem; add structure only for concrete project needs.
|
|
27
|
+
|
|
25
28
|
For `ctx/agent/`, this skill must not:
|
|
26
29
|
|
|
27
30
|
- define or require a template-managed subdirectory structure;
|
|
@@ -32,10 +35,10 @@ When specialization is needed, the agent should use a matching available skill a
|
|
|
32
35
|
|
|
33
36
|
Concrete tool-facing materials belong to project-local documentation, explicit human instruction, or an external specialized skill when one is available and relevant.
|
|
34
37
|
|
|
35
|
-
Specialized skills may add project-specific nested documentation under the four
|
|
38
|
+
Specialized skills may add project-specific nested documentation under the four declarative `ctx/docs` levels and may implement concrete verification methods or project-local feedback procedures. They must preserve agent/skin pairing rules, keep artifacts under `ctx/assets/**`, and treat `verification/` as mandatory cross-cutting documentation rather than a fifth level.
|
|
36
39
|
|
|
37
40
|
## Template Boundary
|
|
38
41
|
|
|
39
42
|
`templates/ctx/` is the reusable initialization baseline. It may establish generic structure, starter documents, and the `ctx/agent/AGENTS.md` boundary, but it must not add project-specific facts or detailed ADSM methodology to project-facing documents.
|
|
40
43
|
|
|
41
|
-
Keep only the minimal bootstrap signal needed to identify an ADSM context and route methodology work to this skill. Use `
|
|
44
|
+
Keep only the minimal bootstrap signal needed to identify an ADSM context and route methodology work to this skill. Use `assets/` only as working material for agent operations; do not install those reports or optional semantic-skin patterns into project context by default.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Semantic Skins
|
|
2
2
|
|
|
3
|
-
- Path: `
|
|
3
|
+
- Path: `skills/adsm-ctx/references/semantic-skins.md`
|
|
4
4
|
- Changed: `20260814`
|
|
5
5
|
|
|
6
6
|
A semantic skin is a compact skeletal human projection of its paired agent document.
|
|
@@ -63,3 +63,5 @@ When creating or reviewing a skin, verify that it:
|
|
|
63
63
|
- adds no untracked facts or requirements and does not contradict its base;
|
|
64
64
|
- excludes operational detail and redundant navigation; and
|
|
65
65
|
- remains compact enough for human cognitive use.
|
|
66
|
+
|
|
67
|
+
Use the [semantic-skin asset](../assets/context/semantic-skin.md) as an optional authoring pattern for authorized work. It is not an initialization template and does not determine the output location; place the resulting skin beside its paired project document.
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
# Specialized Skills
|
|
2
2
|
|
|
3
|
-
- Path: `
|
|
4
|
-
- Changed: `
|
|
3
|
+
- Path: `skills/adsm-ctx/references/specialized-skills.md`
|
|
4
|
+
- Changed: `20260917`
|
|
5
5
|
|
|
6
6
|
Use specialized skills when the project context requires knowledge that should not live in this generic lifecycle skill.
|
|
7
7
|
|
|
@@ -11,6 +11,8 @@ Examples of specialization signals:
|
|
|
11
11
|
- backend application architecture;
|
|
12
12
|
- data or persistence modeling;
|
|
13
13
|
- deployment and runtime environment design;
|
|
14
|
+
- browser, backend, data, security, monitoring, or other concrete verification methods;
|
|
15
|
+
- signal transport, external-report handling, or distributed feedback procedures;
|
|
14
16
|
- tool-specific agent instructions or workflow design for a concrete execution engine or host platform.
|
|
15
17
|
|
|
16
18
|
Tool-specific specialization signals include:
|
|
@@ -27,5 +29,6 @@ Specialized skills must preserve ADSM's documentation projection model:
|
|
|
27
29
|
|
|
28
30
|
- ordinary `*.md` files under `ctx/docs/**` are agent-facing operational context documents;
|
|
29
31
|
- `*.skin.<lang>.md` files are human-facing semantic skins for matching agent documents;
|
|
30
|
-
- nested subdirectories inside the four
|
|
32
|
+
- nested subdirectories inside the four declarative documentation levels are allowed;
|
|
33
|
+
- the mandatory `ctx/docs/verification/` boundary remains cross-cutting; specifications use a primary declaration target rather than the mechanism or specialized skill that obtains evidence;
|
|
31
34
|
- visual, generated, rendered, and auxiliary artifacts belong under `ctx/assets/**`.
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# Root Level
|
|
2
|
+
|
|
3
|
+
- Path: `AGENTS.md`
|
|
4
|
+
- Template Version: `20261024`
|
|
5
|
+
- Changed: `YYYYMMDD`
|
|
6
|
+
|
|
7
|
+
## Boundary
|
|
8
|
+
|
|
9
|
+
This file controls repository work. `ctx/` owns project meaning and is authoritative for product and implementation decisions; consult `ctx/AGENTS.md` and task-relevant context for design or code changes. If implementation conflicts with accepted context, follow the context and report any proposed change to accepted meaning for human approval rather than silently rewriting it. Read navigation documents only when needed and avoid rereading unchanged instructions within a session. Use the `adsm-ctx` skill when available for context lifecycle work.
|
|
10
|
+
|
|
11
|
+
`ctx/` may be part of this repository or a separately mounted repository. Detect its Git boundary before editing, preserve separate histories, and never remove, replace, relocate, or unmount it. If absent, create `ctx/` only when bootstrap is within the assigned scope. Deeper `AGENTS.md` files refine local rules without overriding root invariants.
|
|
12
|
+
|
|
13
|
+
A task may cover multiple repositories. Coordinate affected contracts and consumers, verify their integration, and keep each Git history separate. Do not expand into unrelated repositories. The human defines scope and approves changes to accepted meaning.
|
|
14
|
+
|
|
15
|
+
## Efficient Execution
|
|
16
|
+
|
|
17
|
+
Classify the task before reading context or running checks. Git-only work needs Git-state checks, not product-context scans or tests. For code or context changes, inspect only relevant owners; run deterministic checks chosen by changed responsibility and risk. Capture verbose output outside the model context and inspect logs on failure or when evidence is needed. Report results, omitted coverage, and material risks concisely.
|
|
18
|
+
|
|
19
|
+
Do not modify, replace, delete, or relocate this file without explicit human instruction. Do not read, search, or expose secret-bearing files or credentials; non-secret examples may describe configuration shape. If a secret is accidentally exposed, do not repeat it; notify the human that it should be rotated or revoked.
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# Cognitive Context
|
|
2
|
+
|
|
3
|
+
- Path: `ctx/AGENTS.md`
|
|
4
|
+
- Template Version: `20261024`
|
|
5
|
+
- Changed: `YYYYMMDD`
|
|
6
|
+
|
|
7
|
+
## Purpose
|
|
8
|
+
|
|
9
|
+
This directory contains the project's cognitive context.
|
|
10
|
+
|
|
11
|
+
`docs/` holds authoritative project definitions, `agent/` holds project-local agent operations, and `assets/` holds non-authoritative supporting materials.
|
|
12
|
+
|
|
13
|
+
Keep generic ADSM methodology outside the project context.
|
|
14
|
+
|
|
15
|
+
## Level Map
|
|
16
|
+
|
|
17
|
+
- `agent/` — project-local agent and tool materials.
|
|
18
|
+
- `assets/` — visual, generated, and auxiliary documentation assets.
|
|
19
|
+
- `docs/` — authoritative project documentation and constraints.
|
|
20
|
+
- `AGENTS.md` — context boundary and navigation rules.
|
|
21
|
+
- `README.md` — introductory context information.
|
|
22
|
+
- `adsm.json` — context metadata and versioning.
|
|
23
|
+
|
|
24
|
+
## Level Boundary
|
|
25
|
+
|
|
26
|
+
Defines:
|
|
27
|
+
|
|
28
|
+
- The boundary of the project's cognitive context.
|
|
29
|
+
- Separation of authoritative documentation, agent operations, and supporting assets.
|
|
30
|
+
- Navigation to the appropriate context branch.
|
|
31
|
+
|
|
32
|
+
Does NOT define:
|
|
33
|
+
|
|
34
|
+
- Product, architecture, environment, or code meaning; these belong under `docs/`.
|
|
35
|
+
- Project-local agent workflows; these belong under `agent/`.
|
|
36
|
+
- Generic ADSM methodology; use the `adsm-ctx` skill when available.
|
|
37
|
+
|
|
38
|
+
## Local Reading Map
|
|
39
|
+
|
|
40
|
+
- For initial project orientation, read `docs/ai-intro.md` when needed.
|
|
41
|
+
- For repository topology, consult `docs/filesystem.md`.
|
|
42
|
+
- For product, architecture, environment, or code work, follow `docs/AGENTS.md` and read only task-relevant documentation.
|
|
43
|
+
- For project-local agent operations, follow `agent/AGENTS.md`.
|
|
44
|
+
- For context lifecycle work, use the `adsm-ctx` skill when available.
|
|
45
|
+
|
|
46
|
+
Read `README.md` only when additional orientation is needed. Avoid rereading unchanged context within a session.
|
|
@@ -15,7 +15,7 @@ Detailed ADSM validation and methodology rules are intentionally kept out of thi
|
|
|
15
15
|
## Entry Points
|
|
16
16
|
|
|
17
17
|
- Read `AGENTS.md` for cognitive-context structure and governance rules.
|
|
18
|
-
- Use skill `adsm-ctx` when you need ADSM validation,
|
|
18
|
+
- Use skill `adsm-ctx` when you need ADSM validation, evolution, or methodology guidance.
|
|
19
19
|
- Read `docs/filesystem.md` for the top-level repository map.
|
|
20
20
|
- Read `docs/` for declarative project documentation.
|
|
21
21
|
- Read `agent/` only when working with repository-local agent operations or workflow assets.
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
# Agent Operations
|
|
2
|
+
|
|
3
|
+
- Path: `ctx/agent/AGENTS.md`
|
|
4
|
+
- Template Version: `20261024`
|
|
5
|
+
- Changed: `YYYYMMDD`
|
|
6
|
+
|
|
7
|
+
## Purpose
|
|
8
|
+
|
|
9
|
+
This branch holds project-specific operational materials used by agents and their tools, such as instructions, prompts, workflow definitions, reports, or tool documentation. These are optional examples, not required document types or directories.
|
|
10
|
+
|
|
11
|
+
## Level Map
|
|
12
|
+
|
|
13
|
+
- `AGENTS.md` — agent operations boundary and local navigation.
|
|
14
|
+
|
|
15
|
+
## Level Boundary
|
|
16
|
+
|
|
17
|
+
Defines:
|
|
18
|
+
|
|
19
|
+
- The project-local home for organizing and performing authorized agent work.
|
|
20
|
+
- A project-specific structure beneath this branch; only this file belongs to the reusable initialization baseline.
|
|
21
|
+
|
|
22
|
+
Does NOT define:
|
|
23
|
+
|
|
24
|
+
- Authoritative product, architecture, environment, or code declarations; these belong under `ctx/docs/`.
|
|
25
|
+
- A standard workflow, tool choice, agent role, or required operational subdirectory.
|
|
26
|
+
|
|
27
|
+
## Working Rules
|
|
28
|
+
|
|
29
|
+
- Follow the applicable `AGENTS.md` hierarchy and task-relevant materials listed in the Level Map before acting.
|
|
30
|
+
- Keep operational instructions consistent with accepted declarations in `ctx/docs/` and applicable supervision constraints. They cannot grant authority to change accepted meaning or bypass approval and escalation requirements; surface conflicts to the human.
|
|
31
|
+
- Preserve existing project-specific materials. Add materials only for concrete project needs, without speculative directory scaffolding.
|
|
32
|
+
- Keep the Level Map synchronized with the actual filesystem, listing directories first and sorting each group alphabetically. Follow local instructions in the relevant subdirectory.
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# Project Documentation
|
|
2
|
+
|
|
3
|
+
- Path: `ctx/docs/AGENTS.md`
|
|
4
|
+
- Template Version: `20261024`
|
|
5
|
+
- Changed: `YYYYMMDD`
|
|
6
|
+
|
|
7
|
+
## Purpose
|
|
8
|
+
|
|
9
|
+
This directory contains authoritative project declarations and navigation documents.
|
|
10
|
+
|
|
11
|
+
ADSM defines four ordered declarative levels: product → architecture → environment → code. Lower levels refine upstream meaning without redefining it. Accepted declarations constrain every valid implementation.
|
|
12
|
+
|
|
13
|
+
A mandatory cross-cutting Verification Layer relates declarations to bounded observations of reality. It is not a fifth declarative level and does not establish independent authority over project meaning.
|
|
14
|
+
|
|
15
|
+
## Level Map
|
|
16
|
+
|
|
17
|
+
- `architecture/` — system structure, behavior, state ownership, and integration boundaries.
|
|
18
|
+
- `code/` — implementation constraints and engineering conventions.
|
|
19
|
+
- `environment/` — runtime conditions, infrastructure, and deployment constraints.
|
|
20
|
+
- `product/` — product meaning, domain, roles, and expected outcomes.
|
|
21
|
+
- `verification/` — durable verification specifications; cross-cutting, outside the authority chain.
|
|
22
|
+
- `AGENTS.md` — documentation boundary and working rules.
|
|
23
|
+
- `ai-intro.md` — initial project orientation for agents.
|
|
24
|
+
- `filesystem.md` — top-level repository navigation.
|
|
25
|
+
|
|
26
|
+
Keep this map aligned with the actual project structure. Add optional branches only when adopted.
|
|
27
|
+
|
|
28
|
+
## Level Boundary
|
|
29
|
+
|
|
30
|
+
Defines:
|
|
31
|
+
|
|
32
|
+
- Accepted project declarations and their dependency order.
|
|
33
|
+
- Rules for reading, refining, and maintaining declarative knowledge.
|
|
34
|
+
- Boundaries between declarations, verification specifications, and supporting materials.
|
|
35
|
+
|
|
36
|
+
Does NOT define:
|
|
37
|
+
|
|
38
|
+
- Agent operations and workflows under `ctx/agent/`.
|
|
39
|
+
- Executable product artifacts, runtime state, or operational evidence.
|
|
40
|
+
- Generic ADSM methodology; use the `adsm-ctx` skill when available.
|
|
41
|
+
|
|
42
|
+
## Local Reading Map
|
|
43
|
+
|
|
44
|
+
- For unfamiliar projects, consult `ai-intro.md`.
|
|
45
|
+
- For repository topology, consult `filesystem.md` when needed.
|
|
46
|
+
- For project declarations, follow the relevant level's `AGENTS.md` and read its task-relevant documents.
|
|
47
|
+
- For lower-level changes, consult the upstream declarations needed to establish their meaning and constraints.
|
|
48
|
+
- For Verification Layer work, follow `verification/AGENTS.md`.
|
|
49
|
+
- For context lifecycle, validation, audit, compression, or evolution, use the `adsm-ctx` skill when available.
|
|
50
|
+
|
|
51
|
+
Avoid unnecessary full-context scans and repeated reading of unchanged documents.
|
|
52
|
+
|
|
53
|
+
## Documentation Rules
|
|
54
|
+
|
|
55
|
+
- Preserve the authority order: product → architecture → environment → code. Report missing or conflicting upstream meaning rather than inventing or silently changing it downstream.
|
|
56
|
+
- Keep each durable declaration in its appropriate authoritative document. Preserve consistency across dependent levels.
|
|
57
|
+
- Ordinary `*.md` documents are agent-facing and written in English by default. Optional `*.skin.<lang>.md` files provide human-facing semantic projections.
|
|
58
|
+
- Before editing an agent document, read all matching skins. Preserve their meaning and invariants; report projection drift or required human decisions instead of silently resolving conflicts.
|
|
59
|
+
- Keep documents explicit, focused, and maintainable. Preserve meaningful nested structure and do not sacrifice requirements or precision for brevity.
|
|
60
|
+
- Keep each declarative level within nine direct directories and nine direct ordinary files where practical, excluding `AGENTS.md` and matching skins. Record intentional excess under `## Documentation Capacity Exception` in that level's `AGENTS.md`.
|
|
61
|
+
- Require `verification/AGENTS.md`; the root may contain only this file. Create primary-target categories only for actual durable specifications.
|
|
62
|
+
- Place verification specifications under their primary declarative targets and link secondary declarations. Keep specifications distinct from actual evidence and operational feedback state. Neither evidence nor assessments may redefine accepted meaning.
|
|
63
|
+
- Keep visual, generated, rendered, and auxiliary artifacts under `ctx/assets/**`; they must not introduce authoritative project meaning.
|
|
64
|
+
- Maintain `Path` and `Changed` attributes in stable documents. Delegate detailed methodology and lifecycle procedures to the `adsm-ctx` skill.
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# Testing Overview
|
|
2
|
+
|
|
3
|
+
- Path: `ctx/docs/code/testing.md`
|
|
4
|
+
- Template Version: `20260605`
|
|
5
|
+
- Changed: `YYYYMMDD`
|
|
6
|
+
|
|
7
|
+
## Purpose
|
|
8
|
+
|
|
9
|
+
Describe the test boundary for the project.
|
|
10
|
+
|
|
11
|
+
## Test Structure
|
|
12
|
+
|
|
13
|
+
List the main test layers, directories, and intended verification scope.
|
|
14
|
+
|
|
15
|
+
## Verification Target Boundary
|
|
16
|
+
|
|
17
|
+
Keep executable test organization, framework conventions, fixtures, and isolation in this code-level document. When a project adds a durable specification under the mandatory `ctx/docs/verification/` boundary, that specification states the observed declared expectation and primary target; the executable mechanism remains governed here.
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
# Verification Layer
|
|
2
|
+
|
|
3
|
+
- Path: `ctx/docs/verification/AGENTS.md`
|
|
4
|
+
- Changed: `20261024`
|
|
5
|
+
|
|
6
|
+
## Purpose
|
|
7
|
+
|
|
8
|
+
This mandatory cross-cutting boundary holds durable verification specifications. It is not a fifth declarative authority level. Product → architecture → environment → code remains the ordered hierarchy; humans control accepted meaning.
|
|
9
|
+
|
|
10
|
+
## Level Map
|
|
11
|
+
|
|
12
|
+
- `AGENTS.md` — verification boundary and local routing.
|
|
13
|
+
|
|
14
|
+
## Navigation And Editing
|
|
15
|
+
|
|
16
|
+
The root may contain only `AGENTS.md` when no specifications exist. Create `product/`, `architecture/`, `environment/`, or `code/` only when an actual durable specification belongs there. Route each specification by its primary declarative target, linking secondary targets rather than duplicating it. Preserve useful project-specific nesting and add local routing instructions as needed.
|
|
17
|
+
|
|
18
|
+
Read applicable declarations and matching semantic skins before editing. Preserve traceability, applicability, interpretation bounds, and blind spots. Escalate conflicting accepted meaning to the human.
|
|
19
|
+
|
|
20
|
+
## Level Boundary
|
|
21
|
+
|
|
22
|
+
Defines:
|
|
23
|
+
|
|
24
|
+
- The home and primary-target routing of durable verification specifications.
|
|
25
|
+
- Specification applicability, traceability, and interpretation limits.
|
|
26
|
+
|
|
27
|
+
Does NOT define:
|
|
28
|
+
|
|
29
|
+
- A fifth declarative authority level or changes to accepted declarations.
|
|
30
|
+
- Actual observations, evidence records, or operational feedback state; keep these outside this boundary.
|
|
31
|
+
- Verification coverage or runtime correctness merely from structural conformance.
|
package/src/Init/Service.mjs
CHANGED
|
@@ -5,29 +5,8 @@
|
|
|
5
5
|
* @description Initializes the baseline ADSM context structure in a target project directory.
|
|
6
6
|
*/
|
|
7
7
|
|
|
8
|
-
const templateRoot = new URL("../../
|
|
9
|
-
const rootAgentsTemplate =
|
|
10
|
-
"# Root Level",
|
|
11
|
-
"",
|
|
12
|
-
"- Path: `AGENTS.md`",
|
|
13
|
-
"- Changed: `20260702`",
|
|
14
|
-
"",
|
|
15
|
-
"## Purpose",
|
|
16
|
-
"",
|
|
17
|
-
"Marks the repository root and points agents to the project cognitive context in `ctx/`.",
|
|
18
|
-
"",
|
|
19
|
-
"## Bootstrap Exception",
|
|
20
|
-
"",
|
|
21
|
-
"- `init` and other bootstrap operations may create the initial `ctx/` structure when it does not exist yet.",
|
|
22
|
-
"- This repository uses an ADSM-managed cognitive context.",
|
|
23
|
-
"- Use skill `adsm-ctx` for context validation, upgrades, and methodology rules.",
|
|
24
|
-
"",
|
|
25
|
-
"## Cognitive Context Entry",
|
|
26
|
-
"",
|
|
27
|
-
"- Read `ctx/AGENTS.md` before modifying project files after the context exists.",
|
|
28
|
-
"- Treat `ctx/` as the source of truth for project context after bootstrap is complete.",
|
|
29
|
-
"",
|
|
30
|
-
].join("\n");
|
|
8
|
+
const templateRoot = new URL("../../skills/adsm-ctx/templates/ctx/", import.meta.url);
|
|
9
|
+
const rootAgentsTemplate = new URL("../../skills/adsm-ctx/templates/AGENTS.md", import.meta.url);
|
|
31
10
|
|
|
32
11
|
export default class Service {
|
|
33
12
|
/**
|
|
@@ -81,7 +60,7 @@ export default class Service {
|
|
|
81
60
|
function ensureRootAgents({created, fs, pathService, projectRoot, skipped}) {
|
|
82
61
|
const filePath = pathService.join(projectRoot, "AGENTS.md");
|
|
83
62
|
if (!fs.existsSync(filePath)) {
|
|
84
|
-
fs.writeFileSync(filePath, rootAgentsTemplate);
|
|
63
|
+
fs.writeFileSync(filePath, fs.readFileSync(rootAgentsTemplate, "utf8").replaceAll("YYYYMMDD", new Date().toISOString().slice(0, 10).replaceAll("-", "")));
|
|
85
64
|
created.push("AGENTS.md");
|
|
86
65
|
} else {
|
|
87
66
|
skipped.push("AGENTS.md");
|
|
@@ -127,10 +106,10 @@ function writeMetadata({created, fs, metadata, pathService, projectRoot, skipped
|
|
|
127
106
|
}
|
|
128
107
|
}
|
|
129
108
|
|
|
130
|
-
export const __deps__ = Object.freeze({
|
|
109
|
+
export const __deps__ = Object.freeze({default: Object.freeze({
|
|
131
110
|
copyDirectory: "Fl32_Skill_Adsm_Ctx_Shared_CopyDirectory$",
|
|
132
111
|
fs: "node:fs",
|
|
133
112
|
metadata: "Fl32_Skill_Adsm_Ctx_Shared_Metadata$",
|
|
134
113
|
pathService: "Fl32_Skill_Adsm_Ctx_Shared_Path$",
|
|
135
114
|
url: "node:url",
|
|
136
|
-
});
|
|
115
|
+
})});
|
package/src/Shared/Constants.mjs
CHANGED
|
@@ -8,7 +8,11 @@
|
|
|
8
8
|
export default class Constants {
|
|
9
9
|
constructor() {
|
|
10
10
|
this.CONTEXT_SCHEMA = "adsm-context";
|
|
11
|
-
this.CONTEXT_VERSION = "0.
|
|
11
|
+
this.CONTEXT_VERSION = "0.5.0";
|
|
12
|
+
this.VERIFICATION_CAPABILITY = "verification-layer";
|
|
13
|
+
this.CONTEXT_CAPABILITIES = Object.freeze([this.VERIFICATION_CAPABILITY]);
|
|
14
|
+
this.VERIFICATION_BLOCK = "verification";
|
|
15
|
+
this.VERIFICATION_TARGETS = Object.freeze(["product", "architecture", "environment", "code"]);
|
|
12
16
|
this.DOC_LEVEL_MAX_DIRECTORIES = 9;
|
|
13
17
|
this.DOC_LEVEL_MAX_FILES = 9;
|
|
14
18
|
this.REQUIRED_PATHS = Object.freeze([
|
|
@@ -19,6 +23,8 @@ export default class Constants {
|
|
|
19
23
|
"ctx/docs/architecture",
|
|
20
24
|
"ctx/docs/environment",
|
|
21
25
|
"ctx/docs/code",
|
|
26
|
+
"ctx/docs/verification",
|
|
27
|
+
"ctx/docs/verification/AGENTS.md",
|
|
22
28
|
"ctx/adsm.json",
|
|
23
29
|
"ctx/AGENTS.md",
|
|
24
30
|
"ctx/docs/AGENTS.md",
|