code-anchored-context 0.2.0 → 0.2.2
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/.agents/skills/code-anchored-context/SKILL.md +5 -5
- package/AGENTS.md +12 -11
- package/README.md +7 -7
- package/bin/code-anchored-context.js +11 -10
- package/context/AGENTS.md +2 -2
- package/context/README.md +5 -9
- package/context/_templates/initiative/README.md +2 -2
- package/context/_templates/initiative/release-doc-notes.md +5 -6
- package/context/_templates/planned-initiative/README.md +1 -1
- package/context/_templates/planned-initiative/release-doc-notes.md +4 -5
- package/context/terminology.md +2 -2
- package/package.json +5 -9
- package/product-docs/README.md +61 -0
- package/{docs → product-docs}/_authoring/README.md +6 -6
- package/{docs → product-docs}/_authoring/areas/README.md +2 -2
- package/{docs → product-docs}/_authoring/areas/_template.md +5 -5
- package/{docs → product-docs}/_authoring/terminology.md +1 -1
- package/{docs → product-docs}/_authoring/workflow.md +36 -35
- package/{docs → product-docs}/releases/index.md +2 -2
- package/context/code-anchored-context-structure.md +0 -133
- package/context/code-anchored-context-why.md +0 -80
- package/context/code-anchored-context.html +0 -830
- package/context/giving-ai-agents-context-around-code.md +0 -496
- package/docs/.order +0 -2
- package/docs/Welcome.md +0 -48
- /package/{docs → product-docs}/_templates/area/README.md +0 -0
- /package/{docs → product-docs}/_templates/area/features/feature-template.md +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: code-anchored-context
|
|
3
|
-
description: Use central repository context for planning and implementation. Use when starting, changing, reviewing, or documenting behavior-changing work; when checking or updating context/current.md, context/releases/*/initiatives/*, context/programs/*, context/programs/*/planned-initiatives/*, context/backlog/items/*, specs, plans, interface notes, architecture notes, testing notes, delivery notes, infrastructure notes, actionable operations notes, ADRs, backlog, release-doc-notes.md; when promoting planned initiatives during release transitions; or when deciding whether docs/ should be left untouched.
|
|
3
|
+
description: Use central repository context for planning and implementation. Use when starting, changing, reviewing, or documenting behavior-changing work; when checking or updating context/current.md, context/releases/*/initiatives/*, context/programs/*, context/programs/*/planned-initiatives/*, context/backlog/items/*, specs, plans, interface notes, architecture notes, testing notes, delivery notes, infrastructure notes, actionable operations notes, ADRs, backlog, release-doc-notes.md; when promoting planned initiatives during release transitions; or when deciding whether product-docs/ should be left untouched.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
# Code-Anchored Context
|
|
@@ -175,13 +175,13 @@ settled truth lives. Promote stable conclusions into `spec.md`,
|
|
|
175
175
|
`infrastructure.md`, `operations.md` when actionable, `backlog.md`, ADRs, or
|
|
176
176
|
`release-doc-notes.md` as appropriate.
|
|
177
177
|
|
|
178
|
-
### 9) Preserve The Docs Boundary
|
|
178
|
+
### 9) Preserve The Product Docs Boundary
|
|
179
179
|
|
|
180
|
-
Do not edit `docs/` as part of normal feature work, bug fixes,
|
|
180
|
+
Do not edit `product-docs/` as part of normal feature work, bug fixes,
|
|
181
181
|
refactors, or planning. Instead, update the initiative's
|
|
182
182
|
`release-doc-notes.md`.
|
|
183
183
|
|
|
184
|
-
Only update `docs/` when a human explicitly asks for release
|
|
184
|
+
Only update `product-docs/` when a human explicitly asks for release
|
|
185
185
|
documentation work, a specific page update, or a demonstrable documentation
|
|
186
186
|
fix.
|
|
187
187
|
|
|
@@ -206,4 +206,4 @@ Before finishing behavior-changing work:
|
|
|
206
206
|
infrastructure, actionable operations, or backlog state was reflected in the
|
|
207
207
|
initiative when appropriate.
|
|
208
208
|
- Future product-documentation impact was captured in `release-doc-notes.md`.
|
|
209
|
-
- `docs/` was left untouched unless explicitly requested.
|
|
209
|
+
- `product-docs/` was left untouched unless explicitly requested.
|
package/AGENTS.md
CHANGED
|
@@ -14,18 +14,19 @@ For behavior-changing work, use the repo-wide skill at
|
|
|
14
14
|
Keep initiative knowledge centralized under `context/`; area
|
|
15
15
|
`AGENTS.md` files should point there rather than copying active plans.
|
|
16
16
|
|
|
17
|
-
## Docs Authoring
|
|
17
|
+
## Product Docs Authoring
|
|
18
18
|
|
|
19
|
-
### When To Edit `docs/`
|
|
19
|
+
### When To Edit `product-docs/`
|
|
20
20
|
|
|
21
|
-
Do not edit `docs/` as a side effect of feature work, bug fixes,
|
|
22
|
-
refactors, or other code changes.
|
|
21
|
+
Do not edit `product-docs/` as a side effect of feature work, bug fixes,
|
|
22
|
+
refactors, or other code changes. Product docs in this model are
|
|
23
|
+
release-anchored:
|
|
23
24
|
they describe the behavior of a specific release tag, not the partial state of
|
|
24
25
|
a working branch.
|
|
25
26
|
|
|
26
|
-
Touch `docs/` only when:
|
|
27
|
+
Touch `product-docs/` only when:
|
|
27
28
|
|
|
28
|
-
- A human explicitly asks you to refresh
|
|
29
|
+
- A human explicitly asks you to refresh product docs for a release, typically
|
|
29
30
|
after a release tag is cut and QA has signed off.
|
|
30
31
|
- A human explicitly asks you to create or refresh baseline documentation for
|
|
31
32
|
an existing project.
|
|
@@ -37,16 +38,16 @@ If you are unsure whether the request is one of these, ask before editing.
|
|
|
37
38
|
|
|
38
39
|
If a project has documentation that intentionally follows a different cadence,
|
|
39
40
|
document that exception in the area's README and in
|
|
40
|
-
`docs/_authoring/areas/`.
|
|
41
|
+
`product-docs/_authoring/areas/`.
|
|
41
42
|
|
|
42
43
|
### Where The Authoring Guidance Lives
|
|
43
44
|
|
|
44
45
|
All documentation workflow, per-area authoring guides, and domain terminology
|
|
45
|
-
live under [`docs/_authoring/`](docs/_authoring/). Start
|
|
46
|
-
with [`docs/_authoring/README.md`](docs/_authoring/README.md).
|
|
46
|
+
live under [`product-docs/_authoring/`](product-docs/_authoring/). Start
|
|
47
|
+
with [`product-docs/_authoring/README.md`](product-docs/_authoring/README.md).
|
|
47
48
|
|
|
48
|
-
If you are refreshing docs, the per-area guides in
|
|
49
|
-
[`docs/_authoring/areas/`](docs/_authoring/areas/) tell you
|
|
49
|
+
If you are refreshing product docs, the per-area guides in
|
|
50
|
+
[`product-docs/_authoring/areas/`](product-docs/_authoring/areas/) tell you
|
|
50
51
|
what matters and what to ignore for each area.
|
|
51
52
|
|
|
52
53
|
`AGENTS.md` files stay lean. They are for coding conventions and agent
|
package/README.md
CHANGED
|
@@ -9,7 +9,7 @@ It separates two kinds of truth:
|
|
|
9
9
|
| Folder | Meaning | Updated when |
|
|
10
10
|
| --- | --- | --- |
|
|
11
11
|
| `context/` | What the team is planning, building, deciding, validating, shipping, hosting, deferring, and learning. | During normal development. |
|
|
12
|
-
| `docs/` | What the product does as of a known release or tag. | Only during explicit documentation refresh work. |
|
|
12
|
+
| `product-docs/` | What the product does as of a known release or tag. | Only during explicit documentation refresh work. |
|
|
13
13
|
|
|
14
14
|
The goal is to give humans and AI agents enough structured context to change a
|
|
15
15
|
codebase without relying on chat history, tribal memory, or scattered planning
|
|
@@ -21,8 +21,8 @@ notes.
|
|
|
21
21
|
- `.agents/skills/code-anchored-context/SKILL.md` for the recurring
|
|
22
22
|
working-context workflow.
|
|
23
23
|
- `context/` with terminology, release context, backlog/program structure,
|
|
24
|
-
initiative templates, and
|
|
25
|
-
- `docs/` with a generic release-anchored documentation workflow,
|
|
24
|
+
initiative templates, and release-documentation notes.
|
|
25
|
+
- `product-docs/` with a generic release-anchored documentation workflow,
|
|
26
26
|
authoring guide structure, and area/page templates.
|
|
27
27
|
|
|
28
28
|
## Adopting This In A Project
|
|
@@ -39,7 +39,7 @@ Useful options:
|
|
|
39
39
|
|
|
40
40
|
```bash
|
|
41
41
|
npx code-anchored-context init --dry-run
|
|
42
|
-
npx code-anchored-context init --no-docs
|
|
42
|
+
npx code-anchored-context init --no-product-docs
|
|
43
43
|
npx code-anchored-context init --target ../existing-project
|
|
44
44
|
```
|
|
45
45
|
|
|
@@ -54,8 +54,8 @@ Manual adoption still works:
|
|
|
54
54
|
2. Replace `PROJECT_NAME` placeholders with the project name.
|
|
55
55
|
3. Set the first active release in `context/current.md`.
|
|
56
56
|
4. Add or revise area-specific `AGENTS.md` files so they point back to
|
|
57
|
-
`context/` and `docs/_authoring/`.
|
|
58
|
-
5. Create `docs/_authoring/areas/<area>.md` for each documented
|
|
57
|
+
`context/` and `product-docs/_authoring/`.
|
|
58
|
+
5. Create `product-docs/_authoring/areas/<area>.md` for each documented
|
|
59
59
|
product or code area.
|
|
60
60
|
6. Keep product or domain-specific documentation out of this template repo.
|
|
61
61
|
|
|
@@ -81,5 +81,5 @@ npx @your-scope/code-anchored-context init
|
|
|
81
81
|
Working context can evolve with the branch. Product docs should
|
|
82
82
|
stay stable and release-accurate. When behavior changes during development,
|
|
83
83
|
record future documentation impact in the relevant initiative's
|
|
84
|
-
`release-doc-notes.md`; refresh `docs/` only when that work is
|
|
84
|
+
`release-doc-notes.md`; refresh `product-docs/` only when that work is
|
|
85
85
|
explicitly requested.
|
|
@@ -54,7 +54,7 @@ async function main() {
|
|
|
54
54
|
dryRun: args.dryRun
|
|
55
55
|
});
|
|
56
56
|
|
|
57
|
-
await installer.init({
|
|
57
|
+
await installer.init({ includeProductDocs: args.productDocs });
|
|
58
58
|
}
|
|
59
59
|
|
|
60
60
|
function parseArgs(argv) {
|
|
@@ -65,7 +65,7 @@ function parseArgs(argv) {
|
|
|
65
65
|
release: defaultRelease,
|
|
66
66
|
force: false,
|
|
67
67
|
dryRun: false,
|
|
68
|
-
|
|
68
|
+
productDocs: true,
|
|
69
69
|
help: false,
|
|
70
70
|
version: false
|
|
71
71
|
};
|
|
@@ -95,8 +95,8 @@ function parseArgs(argv) {
|
|
|
95
95
|
continue;
|
|
96
96
|
}
|
|
97
97
|
|
|
98
|
-
if (arg === '--no-docs') {
|
|
99
|
-
options.
|
|
98
|
+
if (arg === '--no-product-docs' || arg === '--no-docs') {
|
|
99
|
+
options.productDocs = false;
|
|
100
100
|
continue;
|
|
101
101
|
}
|
|
102
102
|
|
|
@@ -170,7 +170,8 @@ Options:
|
|
|
170
170
|
--target <path> Project root to install into. Defaults to cwd.
|
|
171
171
|
--project-name <name> Name used to replace PROJECT_NAME placeholders.
|
|
172
172
|
--release <slug> Initial release slug. Defaults to ${defaultRelease}.
|
|
173
|
-
--no-docs
|
|
173
|
+
--no-product-docs Skip the product-docs/ starter files.
|
|
174
|
+
--no-docs Alias for --no-product-docs.
|
|
174
175
|
--force Replace existing generated directories.
|
|
175
176
|
--dry-run Show planned changes without writing files.
|
|
176
177
|
-h, --help Show help.
|
|
@@ -178,7 +179,7 @@ Options:
|
|
|
178
179
|
|
|
179
180
|
Examples:
|
|
180
181
|
npx code-anchored-context init --project-name "My App"
|
|
181
|
-
npx code-anchored-context init --release v1_0_0 --no-docs
|
|
182
|
+
npx code-anchored-context init --release v1_0_0 --no-product-docs
|
|
182
183
|
`);
|
|
183
184
|
}
|
|
184
185
|
|
|
@@ -215,7 +216,7 @@ class Installer {
|
|
|
215
216
|
this.agentsFilePath = path.join(targetRoot, 'AGENTS.md');
|
|
216
217
|
}
|
|
217
218
|
|
|
218
|
-
async init({
|
|
219
|
+
async init({ includeProductDocs }) {
|
|
219
220
|
await this.ensureDirectory(this.targetRoot);
|
|
220
221
|
|
|
221
222
|
await this.installAgentsFile();
|
|
@@ -223,10 +224,10 @@ class Installer {
|
|
|
223
224
|
await this.copyTemplatePath('context', 'context');
|
|
224
225
|
await this.renameReleasePaths();
|
|
225
226
|
|
|
226
|
-
if (
|
|
227
|
-
await this.copyTemplatePath('docs', 'docs');
|
|
227
|
+
if (includeProductDocs) {
|
|
228
|
+
await this.copyTemplatePath('product-docs', 'product-docs');
|
|
228
229
|
} else {
|
|
229
|
-
this.note('skip docs/ (--no-docs)');
|
|
230
|
+
this.note('skip product-docs/ (--no-product-docs)');
|
|
230
231
|
}
|
|
231
232
|
|
|
232
233
|
this.printSummary();
|
package/context/AGENTS.md
CHANGED
|
@@ -14,7 +14,7 @@ only when they are actionable runtime, support, observability, rollback, or
|
|
|
14
14
|
repair context.
|
|
15
15
|
|
|
16
16
|
`context/` describes what is being planned, built, debated, or validated.
|
|
17
|
-
`docs/` describes what has shipped for a release.
|
|
17
|
+
`product-docs/` describes what has shipped for a release.
|
|
18
18
|
|
|
19
19
|
## Editing Rules
|
|
20
20
|
|
|
@@ -22,7 +22,7 @@ repair context.
|
|
|
22
22
|
planned initiatives, release initiatives, backlog items, and promotion.
|
|
23
23
|
- Keep initiative knowledge centralized here. Area `AGENTS.md` files may point
|
|
24
24
|
here, but they should not duplicate initiative content.
|
|
25
|
-
- Do not move in-progress plans into `docs/`.
|
|
25
|
+
- Do not move in-progress plans into `product-docs/`.
|
|
26
26
|
- Use `release-doc-notes.md` inside an initiative to capture what may need to
|
|
27
27
|
become product documentation later.
|
|
28
28
|
- Create initiatives from `context/_templates/initiative/`.
|
package/context/README.md
CHANGED
|
@@ -6,14 +6,10 @@ repository.
|
|
|
6
6
|
Use it for specs, interface notes, architecture notes, testing notes, delivery
|
|
7
7
|
notes, infrastructure notes, actionable operations notes, ADRs, backlog items,
|
|
8
8
|
implementation plans, and release-documentation notes. Do not use
|
|
9
|
-
`docs/` for in-progress development planning.
|
|
9
|
+
`product-docs/` for in-progress development planning.
|
|
10
10
|
|
|
11
11
|
## Start Here
|
|
12
12
|
|
|
13
|
-
- `code-anchored-context.html` is a human-friendly visual brief for this
|
|
14
|
-
opinionated context practice.
|
|
15
|
-
- `giving-ai-agents-context-around-code.md` is an article-form explanation of
|
|
16
|
-
Code-Anchored Context for human-agent collaboration.
|
|
17
13
|
- `terminology.md` defines the shared vocabulary.
|
|
18
14
|
- `current.md` points to the active release context.
|
|
19
15
|
- `programs/` contains durable multi-release working context.
|
|
@@ -24,14 +20,14 @@ implementation plans, and release-documentation notes. Do not use
|
|
|
24
20
|
shape for scoped program work outside the current release.
|
|
25
21
|
- `_templates/release-context/` contains the standard release folder shell.
|
|
26
22
|
|
|
27
|
-
## Relationship To docs/
|
|
23
|
+
## Relationship To product-docs/
|
|
28
24
|
|
|
29
|
-
`context/` and `docs/` serve different jobs:
|
|
25
|
+
`context/` and `product-docs/` serve different jobs:
|
|
30
26
|
|
|
31
27
|
| Folder | Meaning | Updated when |
|
|
32
28
|
| --- | --- | --- |
|
|
33
29
|
| `context/` | What we are planning, building, deciding, or validating. | During normal development. |
|
|
34
|
-
| `docs/` | What the product does as of a release or tag. | Only during explicit documentation refresh work. |
|
|
30
|
+
| `product-docs/` | What the product does as of a release or tag. | Only during explicit documentation refresh work. |
|
|
35
31
|
|
|
36
32
|
Working context can feed release documentation, but it is not product
|
|
37
33
|
documentation. Capture that bridge in each initiative's
|
|
@@ -251,7 +247,7 @@ When changing behavior, agents should:
|
|
|
251
247
|
7. Create or update a program planned initiative when future scoped work is
|
|
252
248
|
clear but belongs outside the current release.
|
|
253
249
|
8. Record future product-doc impact in `release-doc-notes.md`, not in
|
|
254
|
-
`docs/`, unless a human explicitly asks for documentation refresh.
|
|
250
|
+
`product-docs/`, unless a human explicitly asks for documentation refresh.
|
|
255
251
|
|
|
256
252
|
The key rule for planning is:
|
|
257
253
|
|
|
@@ -17,7 +17,7 @@ produce.
|
|
|
17
17
|
- Tests or verification: `path/to/...`
|
|
18
18
|
- Delivery, CI/CD, build, or artifacts: `path/to/...`
|
|
19
19
|
- Infrastructure, IaC, or environment config: `path/to/...`
|
|
20
|
-
-
|
|
20
|
+
- Product docs or release notes: `path/to/...`
|
|
21
21
|
|
|
22
22
|
Remove entries that do not apply and add the real paths. Prefer naming the
|
|
23
23
|
delivery concern over assuming a specific folder layout.
|
|
@@ -59,5 +59,5 @@ support, observability, rollback, or repair context.
|
|
|
59
59
|
Promote settled conclusions into the stable initiative files.
|
|
60
60
|
- Update `release-doc-notes.md` when shipped behavior or product-facing
|
|
61
61
|
behavior changes.
|
|
62
|
-
- Do not update `docs/` from this initiative unless a human
|
|
62
|
+
- Do not update `product-docs/` from this initiative unless a human
|
|
63
63
|
explicitly asks for release documentation work.
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
# Release Doc Notes
|
|
2
2
|
|
|
3
3
|
Use this file to capture product-documentation impact while development is
|
|
4
|
-
in progress. At release time, these notes help refresh `docs/`
|
|
4
|
+
in progress. At release time, these notes help refresh `product-docs/`
|
|
5
5
|
against the final shipped behavior.
|
|
6
6
|
|
|
7
|
-
Do not edit `docs/` from normal development work unless a human
|
|
7
|
+
Do not edit `product-docs/` from normal development work unless a human
|
|
8
8
|
explicitly asks for a documentation refresh or a specific documentation fix.
|
|
9
9
|
|
|
10
10
|
## Product Behavior Changes
|
|
11
11
|
|
|
12
12
|
- None yet.
|
|
13
13
|
|
|
14
|
-
## Candidate Docs Areas
|
|
14
|
+
## Candidate Product Docs Areas
|
|
15
15
|
|
|
16
|
-
- `docs/<Area>/README.md`
|
|
17
|
-
- `docs/<Area>/features/<feature>.md`
|
|
16
|
+
- `product-docs/<Area>/README.md`
|
|
17
|
+
- `product-docs/<Area>/features/<feature>.md`
|
|
18
18
|
|
|
19
19
|
## QA Or Support Notes
|
|
20
20
|
|
|
@@ -32,4 +32,3 @@ ship.
|
|
|
32
32
|
- [ ] Update the relevant product documentation only after release-doc work
|
|
33
33
|
is explicitly requested.
|
|
34
34
|
- [ ] Add the release row if the documentation workflow requires it.
|
|
35
|
-
|
|
@@ -19,7 +19,7 @@ and what outcome it should produce.
|
|
|
19
19
|
- Tests or verification: `path/to/...`
|
|
20
20
|
- Delivery, CI/CD, build, or artifacts: `path/to/...`
|
|
21
21
|
- Infrastructure, IaC, or environment config: `path/to/...`
|
|
22
|
-
-
|
|
22
|
+
- Product docs or release notes: `path/to/...`
|
|
23
23
|
|
|
24
24
|
Remove entries that do not apply and add the real paths. Prefer naming the
|
|
25
25
|
delivery concern over assuming a specific folder layout.
|
|
@@ -4,17 +4,17 @@ Use this file to capture expected product-documentation impact while future
|
|
|
4
4
|
work is being planned. When the planned initiative is promoted and later
|
|
5
5
|
implemented, compare these notes against the final shipped behavior.
|
|
6
6
|
|
|
7
|
-
Do not edit `docs/` from normal development work unless a human
|
|
7
|
+
Do not edit `product-docs/` from normal development work unless a human
|
|
8
8
|
explicitly asks for a documentation refresh or a specific documentation fix.
|
|
9
9
|
|
|
10
10
|
## Expected Product Behavior Changes
|
|
11
11
|
|
|
12
12
|
- None yet.
|
|
13
13
|
|
|
14
|
-
## Candidate Docs Areas
|
|
14
|
+
## Candidate Product Docs Areas
|
|
15
15
|
|
|
16
|
-
- `docs/<Area>/README.md`
|
|
17
|
-
- `docs/<Area>/features/<feature>.md`
|
|
16
|
+
- `product-docs/<Area>/README.md`
|
|
17
|
+
- `product-docs/<Area>/features/<feature>.md`
|
|
18
18
|
|
|
19
19
|
## QA Or Support Notes
|
|
20
20
|
|
|
@@ -25,4 +25,3 @@ explicitly asks for a documentation refresh or a specific documentation fix.
|
|
|
25
25
|
Record details that were considered but should not be documented because
|
|
26
26
|
they are internal implementation details, temporary scaffolding, or might not
|
|
27
27
|
ship.
|
|
28
|
-
|
package/context/terminology.md
CHANGED
|
@@ -9,7 +9,7 @@ backlog items, ADRs, agent summaries, and release-transition work.
|
|
|
9
9
|
| Term | Meaning |
|
|
10
10
|
| --- | --- |
|
|
11
11
|
| `context/` | Working context: plans, specs, ADRs, implementation notes, delivery-surface context, future scope, and release-documentation notes. |
|
|
12
|
-
| `docs/` | Released product documentation. It describes shipped behavior for a release/tag and is not edited during normal development work. |
|
|
12
|
+
| `product-docs/` | Released product documentation. It describes shipped behavior for a release/tag and is not edited during normal development work. |
|
|
13
13
|
| `context/current.md` | Pointer to the current active release context. Updating this is a release transition. |
|
|
14
14
|
| `context/releases/<version>/` | Release-scoped working context for one version. |
|
|
15
15
|
| `context/programs/` | Durable multi-release working context. |
|
|
@@ -60,7 +60,7 @@ both readable Markdown for agents and renderable visual context for humans.
|
|
|
60
60
|
| `infrastructure.md` | Stable description of environment shape, IaC, resources, networking, identity, storage, secrets, and environment dependencies. |
|
|
61
61
|
| `operations.md` | Optional actionable runtime support context: observability, failure modes, rollback, repair, support procedures, and tooling. |
|
|
62
62
|
| `backlog.md` | Trackable work items for the containing initiative or program. |
|
|
63
|
-
| `release-doc-notes.md` | Notes for future product documentation refresh work. This is the bridge to `docs/`. |
|
|
63
|
+
| `release-doc-notes.md` | Notes for future product documentation refresh work. This is the bridge to `product-docs/`. |
|
|
64
64
|
| ADR | Architecture Decision Record. Use for durable decisions and tradeoffs. |
|
|
65
65
|
| `brief.html` | Optional human-friendly presentation layer. |
|
|
66
66
|
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "code-anchored-context",
|
|
3
|
-
"version": "0.2.
|
|
4
|
-
"description": "Install repo-local agent context, release initiatives, and release-anchored docs scaffolding into an existing project.",
|
|
3
|
+
"version": "0.2.2",
|
|
4
|
+
"description": "Install repo-local agent context, release initiatives, and release-anchored product-docs scaffolding into an existing project.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"bin": {
|
|
8
|
-
"code-anchored-context": "
|
|
8
|
+
"code-anchored-context": "bin/code-anchored-context.js"
|
|
9
9
|
},
|
|
10
10
|
"files": [
|
|
11
11
|
"AGENTS.md",
|
|
@@ -14,17 +14,13 @@
|
|
|
14
14
|
"context/README.md",
|
|
15
15
|
"context/_templates/",
|
|
16
16
|
"context/backlog/",
|
|
17
|
-
"context/code-anchored-context-structure.md",
|
|
18
|
-
"context/code-anchored-context-why.md",
|
|
19
|
-
"context/code-anchored-context.html",
|
|
20
17
|
"context/current.md",
|
|
21
|
-
"context/giving-ai-agents-context-around-code.md",
|
|
22
18
|
"context/programs/",
|
|
23
19
|
"context/releases/v0_1_0/README.md",
|
|
24
20
|
"context/releases/v0_1_0/backlog.md",
|
|
25
21
|
"context/releases/v0_1_0/initiatives/.gitkeep",
|
|
26
22
|
"context/terminology.md",
|
|
27
|
-
"docs/",
|
|
23
|
+
"product-docs/",
|
|
28
24
|
"bin/",
|
|
29
25
|
"README.md",
|
|
30
26
|
"LICENSE"
|
|
@@ -41,6 +37,6 @@
|
|
|
41
37
|
"ai",
|
|
42
38
|
"documentation",
|
|
43
39
|
"working-context",
|
|
44
|
-
"docs"
|
|
40
|
+
"product-docs"
|
|
45
41
|
]
|
|
46
42
|
}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
# Product Docs
|
|
2
|
+
|
|
3
|
+
This folder holds release-anchored product documentation for PROJECT_NAME.
|
|
4
|
+
|
|
5
|
+
Product docs describe shipped behavior for a known release, tag, or explicit
|
|
6
|
+
baseline. They are not the place for in-progress planning, implementation
|
|
7
|
+
notes, or draft architecture decisions. Put that work in `context/`.
|
|
8
|
+
|
|
9
|
+
## Start Here
|
|
10
|
+
|
|
11
|
+
- `releases/index.md` records release or baseline documentation refreshes.
|
|
12
|
+
- `_authoring/README.md` explains how humans and agents should author product
|
|
13
|
+
docs.
|
|
14
|
+
- `_authoring/workflow.md` defines when product docs are refreshed and what
|
|
15
|
+
belongs here.
|
|
16
|
+
- `_authoring/areas/` contains per-area authoring guidance.
|
|
17
|
+
|
|
18
|
+
## Standard Layout
|
|
19
|
+
|
|
20
|
+
```text
|
|
21
|
+
product-docs/
|
|
22
|
+
README.md
|
|
23
|
+
releases/
|
|
24
|
+
index.md
|
|
25
|
+
_authoring/
|
|
26
|
+
README.md
|
|
27
|
+
workflow.md
|
|
28
|
+
terminology.md
|
|
29
|
+
areas/
|
|
30
|
+
<area>.md
|
|
31
|
+
_templates/
|
|
32
|
+
area/
|
|
33
|
+
README.md
|
|
34
|
+
features/
|
|
35
|
+
feature-template.md
|
|
36
|
+
<Area>/
|
|
37
|
+
README.md
|
|
38
|
+
features/
|
|
39
|
+
<feature>.md
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Every documented area should have:
|
|
43
|
+
|
|
44
|
+
- a high-level `README.md` that explains the area's purpose and architecture
|
|
45
|
+
- one page per feature under `features/`
|
|
46
|
+
- an authoring guide under `product-docs/_authoring/areas/`
|
|
47
|
+
|
|
48
|
+
## Contributing
|
|
49
|
+
|
|
50
|
+
- Refresh product docs only when explicitly asked.
|
|
51
|
+
- For existing projects with little or no product documentation, create
|
|
52
|
+
baseline product docs only when explicitly asked; otherwise document touched
|
|
53
|
+
behavior during future release refreshes.
|
|
54
|
+
- Write for non-developer technical readers unless the project states
|
|
55
|
+
otherwise.
|
|
56
|
+
- Write from behavior outward: product-readable first, technically anchored
|
|
57
|
+
where details affect shipped behavior, operations, or support.
|
|
58
|
+
- Describe behavior, inputs, outputs, permissions, errors, business rules, and
|
|
59
|
+
operational expectations in domain language.
|
|
60
|
+
- Prefer Mermaid diagrams for flows, architecture, and relationships.
|
|
61
|
+
- Add release refreshes to `product-docs/releases/index.md`.
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
# Docs Authoring Guide
|
|
1
|
+
# Product Docs Authoring Guide
|
|
2
2
|
|
|
3
3
|
This subtree owns all guidance for authoring and refreshing the documentation
|
|
4
|
-
under `docs/`. Humans and agents both read from here to know how
|
|
4
|
+
under `product-docs/`. Humans and agents both read from here to know how
|
|
5
5
|
documentation is structured, when it is refreshed, what belongs in each area,
|
|
6
6
|
and which domain terminology to use.
|
|
7
7
|
|
|
8
8
|
## Start Here
|
|
9
9
|
|
|
10
|
-
- [`workflow.md`](workflow.md) explains how docs are versioned,
|
|
11
|
-
structured.
|
|
10
|
+
- [`workflow.md`](workflow.md) explains how product docs are versioned,
|
|
11
|
+
refreshed, and structured.
|
|
12
12
|
- [`terminology.md`](terminology.md) holds project-specific domain language.
|
|
13
13
|
- [`areas/`](areas/) contains one file per documented area, covering feature
|
|
14
14
|
inventory, code orientation, conventions, and what matters at release time.
|
|
@@ -18,14 +18,14 @@ and which domain terminology to use.
|
|
|
18
18
|
Create one authoring guide per documented area:
|
|
19
19
|
|
|
20
20
|
```text
|
|
21
|
-
docs/_authoring/areas/<area-slug>.md
|
|
21
|
+
product-docs/_authoring/areas/<area-slug>.md
|
|
22
22
|
```
|
|
23
23
|
|
|
24
24
|
Each area guide should identify:
|
|
25
25
|
|
|
26
26
|
- the source locations that own the behavior, such as product code,
|
|
27
27
|
interfaces, tests, CI/CD, generated artifacts, infrastructure, or config
|
|
28
|
-
- the docs root under `docs/`
|
|
28
|
+
- the product docs root under `product-docs/`
|
|
29
29
|
- feature pages that should exist
|
|
30
30
|
- behavior that matters at release time
|
|
31
31
|
- changes to ignore, such as pure refactors or test-only edits
|
|
@@ -5,10 +5,10 @@ This folder contains one authoring guide per documented area.
|
|
|
5
5
|
Create a guide from `_template.md` when adding a documentation area:
|
|
6
6
|
|
|
7
7
|
```text
|
|
8
|
-
docs/_authoring/areas/<area-slug>.md
|
|
8
|
+
product-docs/_authoring/areas/<area-slug>.md
|
|
9
9
|
```
|
|
10
10
|
|
|
11
|
-
Each guide should help a human or agent refresh docs from a release diff
|
|
11
|
+
Each guide should help a human or agent refresh product docs from a release diff
|
|
12
12
|
without rediscovering the area's structure from scratch.
|
|
13
13
|
|
|
14
14
|
## Current Area Guides
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
- Source orientation: `path/to/runtime-or-product-code`, `path/to/contracts`,
|
|
6
6
|
`path/to/tests`, `path/to/ci-or-delivery`, `path/to/infra-or-config`
|
|
7
|
-
-
|
|
7
|
+
- Product docs root: `product-docs/<Area>/`
|
|
8
8
|
- Owner or reviewer: TBD
|
|
9
9
|
|
|
10
10
|
Describe what this area owns and what it intentionally does not own.
|
|
@@ -18,9 +18,9 @@ operational expectations without private implementation detail.
|
|
|
18
18
|
|
|
19
19
|
## Feature Inventory
|
|
20
20
|
|
|
21
|
-
| Feature |
|
|
21
|
+
| Feature | Product docs page | Notes |
|
|
22
22
|
| --- | --- | --- |
|
|
23
|
-
| TBD | `docs/<Area>/features/<feature>.md` | TBD |
|
|
23
|
+
| TBD | `product-docs/<Area>/features/<feature>.md` | TBD |
|
|
24
24
|
|
|
25
25
|
## What Matters At Release Time
|
|
26
26
|
|
|
@@ -57,9 +57,9 @@ known gaps, and questions that should not yet appear in product-facing docs.
|
|
|
57
57
|
|
|
58
58
|
## Terminology
|
|
59
59
|
|
|
60
|
-
List area-specific terms or link to `docs/_authoring/terminology.md`.
|
|
60
|
+
List area-specific terms or link to `product-docs/_authoring/terminology.md`.
|
|
61
61
|
|
|
62
62
|
## Cross-Links
|
|
63
63
|
|
|
64
|
-
List related areas and when docs should cross-link instead of duplicating
|
|
64
|
+
List related areas and when product docs should cross-link instead of duplicating
|
|
65
65
|
behavior.
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
Use this file to define the domain language that documentation should use.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Product docs should translate code-level names into reader-facing domain
|
|
6
6
|
terms when those differ. The goal is consistency for QA, product, support,
|
|
7
7
|
operators, and future agents.
|
|
8
8
|
|