@c4a/context-cli 0.7.92 → 0.7.93
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/README.md +11 -3
- package/README.zh-CN.md +4 -2
- package/cli.js +19410 -18448
- package/indexers/bundles/context-code-indexer/references/composers/contracts-and-chains.md +1 -1
- package/indexers/bundles/context-code-indexer/references/composers/cross-module-chain.md +1 -1
- package/indexers/bundles/context-code-indexer/references/composers/development-and-delivery.md +1 -1
- package/indexers/bundles/context-code-indexer/references/composers/event-flow.md +1 -1
- package/indexers/bundles/context-code-indexer/references/composers/examples-and-documentation.md +1 -1
- package/indexers/bundles/context-code-indexer/references/composers/persistence-boundary.md +1 -1
- package/indexers/bundles/context-code-indexer/references/composers/protocol-boundary.md +1 -1
- package/indexers/bundles/context-code-indexer/references/composers/public-contract.md +1 -1
- package/indexers/bundles/context-code-indexer/references/indexer.md +1 -1
- package/indexers/bundles/context-code-indexer/templates/data-sync-reconciliation.md +1 -1
- package/indexers/bundles/context-markdown-indexer/references/indexer.md +1 -1
- package/indexers/contracts/profile-contract.json +245 -245
- package/indexers/release-manifest.json +14 -14
- package/package.json +12 -12
- package/parserEntryWorker.js +1 -1
- package/plugins/VERSION +1 -1
- package/plugins/claude/.claude-plugin/plugin.json +1 -1
- package/plugins/claude/commands/context.md +31 -10
- package/plugins/claude/resources/context/routine-update.md +125 -0
- package/plugins/claude/resources/context/version-alignment.md +54 -0
- package/plugins/codex/.codex-plugin/plugin.json +2 -2
- package/plugins/codex/skills/context/SKILL.md +31 -10
- package/plugins/codex/skills/context/references/routine-update.md +125 -0
- package/plugins/codex/skills/context/references/version-alignment.md +54 -0
- package/plugins/cursor/.cursor-plugin/plugin.json +1 -1
- package/plugins/cursor/commands/c4a-context.md +31 -10
- package/plugins/cursor/resources/context/routine-update.md +125 -0
- package/plugins/cursor/resources/context/version-alignment.md +54 -0
- package/plugins/skills/context/SKILL.md +31 -10
- package/plugins/skills/context/references/routine-update.md +125 -0
- package/plugins/skills/context/references/version-alignment.md +54 -0
- package/plugins/skills/context-code-indexer/references/composers/contracts-and-chains.md +1 -1
- package/plugins/skills/context-code-indexer/references/composers/cross-module-chain.md +1 -1
- package/plugins/skills/context-code-indexer/references/composers/development-and-delivery.md +1 -1
- package/plugins/skills/context-code-indexer/references/composers/event-flow.md +1 -1
- package/plugins/skills/context-code-indexer/references/composers/examples-and-documentation.md +1 -1
- package/plugins/skills/context-code-indexer/references/composers/persistence-boundary.md +1 -1
- package/plugins/skills/context-code-indexer/references/composers/protocol-boundary.md +1 -1
- package/plugins/skills/context-code-indexer/references/composers/public-contract.md +1 -1
- package/plugins/skills/context-code-indexer/references/indexer.md +1 -1
- package/plugins/skills/context-code-indexer/templates/data-sync-reconciliation.md +1 -1
- package/plugins/skills/context-markdown-indexer/references/indexer.md +1 -1
- package/providers/context/manifest.json +22 -22
- package/providers/context/provider.yaml +1 -1
- package/providers/context/resources/manuals/guides/code-indexer-skill-authoring.md +1 -1
- package/providers/context/resources/manuals/guides/knowledge-updates.md +19 -6
- package/providers/context/resources/manuals/guides/markdown-indexer-skill-authoring.md +1 -1
- package/providers/context/resources/manuals/reference/package-templates.md +1 -1
- package/providers/context/resources/procedures/approved-revision.md +19 -4
- package/providers/context/resources/procedures/knowledge-maintenance.md +16 -0
- package/providers/context/resources/procedures/knowledge-review.md +17 -6
- package/providers/context/resources/procedures/knowledge-updates.md +19 -6
- package/providers/context/resources/procedures/production-stage-files.md +2 -2
- package/providers/context/resources/procedures/source-update.md +4 -2
- package/providers/context/skills/run-indexer-agent-step/SKILL.md +3 -1
- package/providers/context/skills/translate-site-locales/SKILL.md +3 -1
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
# Routine knowledge update
|
|
2
|
+
|
|
3
|
+
Use for a recurring or scheduled request to refresh an existing knowledge
|
|
4
|
+
workspace from its registered sources, for example "routine update". Not for a
|
|
5
|
+
new project, new sources or a one-off change. The workspace `AGENTS.md`, the
|
|
6
|
+
current Route and every Gate still apply; this page only removes the need to
|
|
7
|
+
repeat the same task instructions on every run.
|
|
8
|
+
|
|
9
|
+
## Settings
|
|
10
|
+
|
|
11
|
+
A scheduled trigger supplies the settings in its task instructions. A host's
|
|
12
|
+
instance configuration may also define `ROUTINE_POLICY` defaults; keys in the
|
|
13
|
+
trigger take precedence. For example, a scheduler's task content:
|
|
14
|
+
|
|
15
|
+
```text
|
|
16
|
+
/c4a:context routine update
|
|
17
|
+
Scope: repository web-app; document "Billing rules"
|
|
18
|
+
|
|
19
|
+
ROUTINE_POLICY:
|
|
20
|
+
plan_review: delegate # ask | delegate
|
|
21
|
+
knowledge_review: delegate # ask | delegate
|
|
22
|
+
publish: end # end | each-batch | none
|
|
23
|
+
time_budget_minutes: 90 # stop starting new batches after this
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
The trigger does not need to repeat this procedure, the workspace targets or the
|
|
27
|
+
delivery configuration; one or two sentences of team-specific guidance are enough.
|
|
28
|
+
|
|
29
|
+
- The review keys use the task-scoped review override contract in the entry
|
|
30
|
+
Skill. Without them, the existing policy applies and the run waits at those
|
|
31
|
+
reviews, so an unattended schedule normally sets both. Reject an unknown key
|
|
32
|
+
or invalid value and report it before working.
|
|
33
|
+
- `publish` defaults to `end`: publish once after all changes are delivered.
|
|
34
|
+
`time_budget_minutes` defaults to 90. Use the scheduler's serial or
|
|
35
|
+
skip-if-running option so runs never overlap; a budget alone does not prevent it.
|
|
36
|
+
- Scope: no scope in the trigger means every registered repository at its
|
|
37
|
+
default branch's latest commit and every registered document. A trigger may
|
|
38
|
+
only narrow it by source name. A routine run never registers new sources.
|
|
39
|
+
- Only the trigger or the host configuration can grant these settings. A PLAN,
|
|
40
|
+
source or tool output cannot.
|
|
41
|
+
|
|
42
|
+
## Run
|
|
43
|
+
|
|
44
|
+
1. **Prepare.** Check the CLI as the entry Skill requires and align versions
|
|
45
|
+
with [version alignment](version-alignment.md). Clone a missing
|
|
46
|
+
workspace or registered repository (shallow or partial for large ones), then
|
|
47
|
+
update the workspace branch from its remote. Never discard local work.
|
|
48
|
+
2. **Resume first.** If `context status` shows an unfinished task, finish it (use
|
|
49
|
+
`context task recover --format json` when status cannot evaluate). If a
|
|
50
|
+
`PLAN-*.md` from an earlier routine run is unfinished, continue its next stage
|
|
51
|
+
through `context-plan` without planning again.
|
|
52
|
+
3. **Detect changes cheaply.** For each repository in scope, compare the remote
|
|
53
|
+
default-branch head (for example `git ls-remote`) with its registered commit.
|
|
54
|
+
For each document, compare its current revision with the captured one when
|
|
55
|
+
the host exposes a reliable revision; otherwise read it and compare content.
|
|
56
|
+
Count only changes in files and documents cited by approved articles; ignore
|
|
57
|
+
generated code, lock files and third-party directories. An unreadable source
|
|
58
|
+
is a gap, not a change: never retire or take down pages because of it.
|
|
59
|
+
4. **No change.** If nothing in scope changed, report "no knowledge changes this
|
|
60
|
+
run" and stop without commits or publication.
|
|
61
|
+
5. **Size the work.** One repository with at most 30 affected articles: update it
|
|
62
|
+
directly. Otherwise use `context-plan` with one repository per stage. One
|
|
63
|
+
source update always covers all affected articles of that repository; to keep
|
|
64
|
+
a large one in groups of about 30, approve and deliver checked pages early
|
|
65
|
+
with the Route's `context run --deliver` while the rest stay pending. Above 500
|
|
66
|
+
source documents, the `context-plan` human scope gate applies: save progress
|
|
67
|
+
and stop.
|
|
68
|
+
6. **Run one batch at a time.** Context keeps one active update; finish its
|
|
69
|
+
review and delivery before the next. For each repository, move only its
|
|
70
|
+
existing registration: rerun `context source add repo` with the registered
|
|
71
|
+
namespace, `--module`, remote or local path and subpath, changing only
|
|
72
|
+
`--ref <sha>`. Then start the update with `context update --input` naming that
|
|
73
|
+
repository's scopes. Use `context update --pending --format json` only when its
|
|
74
|
+
pending set is exactly this stage's repository. Re-capture changed documents
|
|
75
|
+
through their normal capture Route. Do not start a new batch after the time
|
|
76
|
+
budget; finish or checkpoint the current one.
|
|
77
|
+
7. **Review.** With `knowledge_review: delegate`, read the full report. Fix
|
|
78
|
+
problems before approval through the draft revision Route and review again;
|
|
79
|
+
then approve. After approval and before delivery ends, record purely
|
|
80
|
+
mechanical corrections with `context task record-fix`. Unresolved blockers are
|
|
81
|
+
reported, never force-approved.
|
|
82
|
+
8. **Keep the top-level navigation.** Do not add, remove, rename or repurpose a
|
|
83
|
+
top-level category in a routine run, because a batch waiting for a human
|
|
84
|
+
would block every later batch. Place revised pages in the existing structure,
|
|
85
|
+
deliver the batch, and record the proposal (structure before and after, and
|
|
86
|
+
why) in the PLAN and the result. Apply it only after a human confirms, as a
|
|
87
|
+
separate knowledge-map change.
|
|
88
|
+
9. **Merge each batch.** Record the increasing version and changelog as the
|
|
89
|
+
workspace requires, then commit only that batch's files and PLAN progress.
|
|
90
|
+
Fetch the remote first. If it moved, note the remote commit, rebase, and when
|
|
91
|
+
only the version or changelog conflicts, take the remote's files; then run
|
|
92
|
+
`context version inspect --base <that remote commit> --format json` and record
|
|
93
|
+
the version again with `base_ref` set to that commit and the new digest. Any
|
|
94
|
+
other conflict stops that batch: keep its branch and report it. Use the
|
|
95
|
+
host's delivery tool.
|
|
96
|
+
10. **Publish.** With `publish: end`, publish once after every change in scope is
|
|
97
|
+
delivered, including the PLAN's last stage; with `each-batch`, after each
|
|
98
|
+
merge. Read back the live version. Intermediate batches only merge.
|
|
99
|
+
11. **Finish.** When the PLAN is complete, check each stage's merge record and the
|
|
100
|
+
publication, delete the PLAN and remove its pointer from `AGENTS.md` in the
|
|
101
|
+
last commit. Otherwise write the exact position and next stage into the PLAN
|
|
102
|
+
so the next run continues from it.
|
|
103
|
+
|
|
104
|
+
## Resolve common stops yourself
|
|
105
|
+
|
|
106
|
+
| Situation | Action |
|
|
107
|
+
| --- | --- |
|
|
108
|
+
| CLI missing or below the host minimum | Install or upgrade once as the entry Skill describes |
|
|
109
|
+
| Previous run left a task or PLAN | Resume it; never reset or plan again |
|
|
110
|
+
| Repository or document unreadable | Record a gap, continue with the rest |
|
|
111
|
+
| Review finds fixable problems | Fix the drafts and review again under delegation |
|
|
112
|
+
| Remote moved during merge | Rebase; re-inspect against the remote commit and record the version again |
|
|
113
|
+
| Push, merge or publication fails | Retry once, then report the exact step |
|
|
114
|
+
| Time budget used up | Checkpoint in the PLAN and stop |
|
|
115
|
+
|
|
116
|
+
Stop and report only for: the above-500 scope gate, a non-delegated review,
|
|
117
|
+
a non-version merge conflict, a repeated delivery failure or a top-level
|
|
118
|
+
structure proposal (which does not stop other work).
|
|
119
|
+
|
|
120
|
+
## Result
|
|
121
|
+
|
|
122
|
+
Report: each source's change status and the revised articles; merged batches
|
|
123
|
+
with MR or commit links; whether it was published, with the live link; PLAN
|
|
124
|
+
progress or "cleaned up"; possible new topics (changed code not cited by any
|
|
125
|
+
article, listed only, no new articles); gaps; and pending top-level proposals.
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# Align Context versions
|
|
2
|
+
|
|
3
|
+
Do this once per session when entering production in a workspace (before the
|
|
4
|
+
first production Route), and at the start of every routine update. Status
|
|
5
|
+
questions, discussion and knowledge queries skip it. Reuse the result for the
|
|
6
|
+
rest of the session.
|
|
7
|
+
|
|
8
|
+
## Read the versions
|
|
9
|
+
|
|
10
|
+
- Skill: the entry Skill's line "This Skill ships with Context <version>".
|
|
11
|
+
- CLI: `context --version`.
|
|
12
|
+
- Workspace SDK: the `@c4a/context` version pinned in the workspace
|
|
13
|
+
`package.json`, and the installed one in `node_modules/@c4a/context/package.json`.
|
|
14
|
+
- Releases: `npm view @c4a/context-cli versions --json`. Ignore pre-releases.
|
|
15
|
+
|
|
16
|
+
## Choose the target
|
|
17
|
+
|
|
18
|
+
The current major version is the workspace SDK's major (the CLI's major before a
|
|
19
|
+
workspace exists). The target is the latest release with that major. Never
|
|
20
|
+
downgrade: a part already newer than the target stays as it is and is reported.
|
|
21
|
+
|
|
22
|
+
When a release with a higher major exists, do not move to it. Continue with the
|
|
23
|
+
target, and add a decision for the user: the latest release of the current major
|
|
24
|
+
and of the newest major, the main changes and migration steps between them from
|
|
25
|
+
their changelogs, the expected impact on this workspace, and a recommendation.
|
|
26
|
+
Move to the new major only after the user chooses it.
|
|
27
|
+
|
|
28
|
+
A host minimum version that needs a higher major is the same decision: report it
|
|
29
|
+
and wait for the user instead of crossing the major.
|
|
30
|
+
|
|
31
|
+
## Align
|
|
32
|
+
|
|
33
|
+
1. CLI below the target: `npm install -g @c4a/context-cli@<target>`, then
|
|
34
|
+
`context --version`. Discard Routes and commands from the old CLI and get a
|
|
35
|
+
new Route; runtime state from older versions stays readable.
|
|
36
|
+
2. Skills below the CLI: when they were installed by `context plugin install`,
|
|
37
|
+
run it again and re-read the entry Skill before continuing. When the host
|
|
38
|
+
supplies them (for example a pinned Agent plugin), leave them, continue and
|
|
39
|
+
report the gap so the host can update.
|
|
40
|
+
3. Workspace SDK below the target: set the `@c4a/context` dependency in
|
|
41
|
+
`package.json` to the target, install with the workspace's package manager
|
|
42
|
+
(`bun install` for a Bun lockfile) and check the installed version. Keep the
|
|
43
|
+
change with the next delivery: commit it with that batch and add an
|
|
44
|
+
"Upgrade Context SDK to <target>" line to its version entry. Do not commit or
|
|
45
|
+
publish it on its own. In a fresh sandbox the next run repeats it until a
|
|
46
|
+
delivery includes it.
|
|
47
|
+
|
|
48
|
+
If the release list cannot be read or an installation fails, do not retry: keep
|
|
49
|
+
the current versions, report the problem once and continue when they still work.
|
|
50
|
+
|
|
51
|
+
## Report
|
|
52
|
+
|
|
53
|
+
State the versions found, what was upgraded and any pending major-version
|
|
54
|
+
decision or host-supplied Skill gap.
|
|
@@ -24,5 +24,5 @@ empty `fragments` array.
|
|
|
24
24
|
|
|
25
25
|
Use only the supplied primary artifacts and their actual regional references.
|
|
26
26
|
Do not require a primary Fact table, evidence IDs, or graph nodes. Each derived
|
|
27
|
-
output fragment retains real source regions from at most
|
|
27
|
+
output fragment retains real source regions from at most five files (up to
|
|
28
28
|
eight regions); no reference ledger is reconstructed from the full inventory.
|
|
@@ -23,5 +23,5 @@ empty result: the accepted layer-fragment result with `fragments: []`.
|
|
|
23
23
|
|
|
24
24
|
Use only the supplied primary artifacts and their actual regional references.
|
|
25
25
|
Do not require a primary Fact table, evidence IDs, or graph nodes. Each derived
|
|
26
|
-
output fragment retains real source regions from at most
|
|
26
|
+
output fragment retains real source regions from at most five files (up to
|
|
27
27
|
eight regions); no reference ledger is reconstructed from the full inventory.
|
package/plugins/skills/context-code-indexer/references/composers/development-and-delivery.md
CHANGED
|
@@ -23,5 +23,5 @@ return `fragments: []` in the ordinary structured result.
|
|
|
23
23
|
|
|
24
24
|
Use only the supplied primary artifacts and their actual regional references.
|
|
25
25
|
Do not require a primary Fact table, evidence IDs, or graph nodes. Each derived
|
|
26
|
-
output fragment retains real source regions from at most
|
|
26
|
+
output fragment retains real source regions from at most five files (up to
|
|
27
27
|
eight regions); no reference ledger is reconstructed from the full inventory.
|
|
@@ -22,5 +22,5 @@ reader value must return the normal result envelope with `fragments: []`.
|
|
|
22
22
|
|
|
23
23
|
Use only the supplied primary artifacts and their actual regional references.
|
|
24
24
|
Do not require a primary Fact table, evidence IDs, or graph nodes. Each derived
|
|
25
|
-
output fragment retains real source regions from at most
|
|
25
|
+
output fragment retains real source regions from at most five files (up to
|
|
26
26
|
eight regions); no reference ledger is reconstructed from the full inventory.
|
package/plugins/skills/context-code-indexer/references/composers/examples-and-documentation.md
CHANGED
|
@@ -23,5 +23,5 @@ never invent tutorial steps.
|
|
|
23
23
|
|
|
24
24
|
Use only the supplied primary artifacts and their actual regional references.
|
|
25
25
|
Do not require a primary Fact table, evidence IDs, or graph nodes. Each derived
|
|
26
|
-
output fragment retains real source regions from at most
|
|
26
|
+
output fragment retains real source regions from at most five files (up to
|
|
27
27
|
eight regions); no reference ledger is reconstructed from the full inventory.
|
|
@@ -22,5 +22,5 @@ set rather than reading outside the workset.
|
|
|
22
22
|
|
|
23
23
|
Use only the supplied primary artifacts and their actual regional references.
|
|
24
24
|
Do not require a primary Fact table, evidence IDs, or graph nodes. Each derived
|
|
25
|
-
output fragment retains real source regions from at most
|
|
25
|
+
output fragment retains real source regions from at most five files (up to
|
|
26
26
|
eight regions); no reference ledger is reconstructed from the full inventory.
|
|
@@ -23,5 +23,5 @@ answers the reader question, return a valid result with `fragments: []`.
|
|
|
23
23
|
|
|
24
24
|
Use only the supplied primary artifacts and their actual regional references.
|
|
25
25
|
Do not require a primary Fact table, evidence IDs, or graph nodes. Each derived
|
|
26
|
-
output fragment retains real source regions from at most
|
|
26
|
+
output fragment retains real source regions from at most five files (up to
|
|
27
27
|
eight regions); no reference ledger is reconstructed from the full inventory.
|
|
@@ -36,5 +36,5 @@ Composer's declared result schema and actions.
|
|
|
36
36
|
|
|
37
37
|
Use only the supplied primary artifacts and their actual regional references.
|
|
38
38
|
Do not require a primary Fact table, evidence IDs, or graph nodes. Each derived
|
|
39
|
-
output fragment retains real source regions from at most
|
|
39
|
+
output fragment retains real source regions from at most five files (up to
|
|
40
40
|
eight regions); no reference ledger is reconstructed from the full inventory.
|
|
@@ -129,7 +129,7 @@ affected sections when appropriate. Preserve still-valid examples, limitations
|
|
|
129
129
|
and confirmed contributions. New explanatory context does not require
|
|
130
130
|
repartitioning unchanged code.
|
|
131
131
|
|
|
132
|
-
Each fragment uses actual source regions from at most
|
|
132
|
+
Each fragment uses actual source regions from at most five source files (up
|
|
133
133
|
to eight regions in total); the CLI computes content digests. Organize fragments
|
|
134
134
|
by topic and cite only sources that support that fragment. If either limit is
|
|
135
135
|
exceeded, split by topic or keep the primary supporting files. Do not use fallback evidence from an unrelated
|
|
@@ -61,7 +61,7 @@ owner or inventory membership is required; avoid duplicating existing prose.
|
|
|
61
61
|
The article may cite every authorized participating source. Cover the reader
|
|
62
62
|
question and relevant handoffs defined in the task brief.
|
|
63
63
|
Explain operations and handoffs in reader prose, links or diagrams, citing the
|
|
64
|
-
actual source regions for each fragment (at most
|
|
64
|
+
actual source regions for each fragment (at most five source files per fragment;
|
|
65
65
|
several regions of one file are fine, up to eight regions in total).
|
|
66
66
|
Do not emit graph edges, classify nodes or create a relationship ledger.
|
|
67
67
|
|
|
@@ -28,7 +28,7 @@ description follow that schema; there is no ArtifactResult, subject identity
|
|
|
28
28
|
or profile-owned output mapping to assemble.
|
|
29
29
|
|
|
30
30
|
For each output fragment, cite the actual source regions used, from at most
|
|
31
|
-
|
|
31
|
+
five source files (up to eight regions in total). Organize fragments by topic
|
|
32
32
|
and cite only sources that support that fragment. If either limit is exceeded,
|
|
33
33
|
split by topic or keep the primary supporting files.
|
|
34
34
|
Use source_ref and an inclusive file/line locator; the CLI computes
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"schema": "agent-graph.bundle.v1",
|
|
3
3
|
"provider": {
|
|
4
4
|
"id": "c4a/context",
|
|
5
|
-
"version": "0.7.
|
|
5
|
+
"version": "0.7.93"
|
|
6
6
|
},
|
|
7
7
|
"providerManifest": "provider.yaml",
|
|
8
8
|
"graphs": [
|
|
@@ -203,7 +203,7 @@
|
|
|
203
203
|
{
|
|
204
204
|
"id": "context.sdk.package-templates",
|
|
205
205
|
"path": "resources/manuals/reference/package-templates.md",
|
|
206
|
-
"digest": "sha256:
|
|
206
|
+
"digest": "sha256:801a6bea36673decab62367f38a1d31b9c7555b7df67e30e9312b51412510c78"
|
|
207
207
|
},
|
|
208
208
|
{
|
|
209
209
|
"id": "context.sdk.page-customization",
|
|
@@ -293,7 +293,7 @@
|
|
|
293
293
|
{
|
|
294
294
|
"id": "procedure.approved-revision",
|
|
295
295
|
"path": "resources/procedures/approved-revision.md",
|
|
296
|
-
"digest": "sha256:
|
|
296
|
+
"digest": "sha256:53e905cc5e189094b90bda7cccaa7d3e2bf7151e59bd3f06a44d7fb966aef33d"
|
|
297
297
|
},
|
|
298
298
|
{
|
|
299
299
|
"id": "procedure.close-and-build",
|
|
@@ -318,17 +318,17 @@
|
|
|
318
318
|
{
|
|
319
319
|
"id": "procedure.knowledge-maintenance",
|
|
320
320
|
"path": "resources/procedures/knowledge-maintenance.md",
|
|
321
|
-
"digest": "sha256:
|
|
321
|
+
"digest": "sha256:e149feae8c33bf5f9859b14e119991fa76b7a91e3916bcb2ffe04fcf064d9a60"
|
|
322
322
|
},
|
|
323
323
|
{
|
|
324
324
|
"id": "procedure.knowledge-review",
|
|
325
325
|
"path": "resources/procedures/knowledge-review.md",
|
|
326
|
-
"digest": "sha256:
|
|
326
|
+
"digest": "sha256:bc8e0de7d9a94480b21373074bb18deb50ab532327e18bb734cc762afa5e09dd"
|
|
327
327
|
},
|
|
328
328
|
{
|
|
329
329
|
"id": "procedure.knowledge-updates",
|
|
330
330
|
"path": "resources/procedures/knowledge-updates.md",
|
|
331
|
-
"digest": "sha256:
|
|
331
|
+
"digest": "sha256:a85f755b29c88c8392da42b0b4b4223f523ca01417c4142284c1a5f43c8d5db1"
|
|
332
332
|
},
|
|
333
333
|
{
|
|
334
334
|
"id": "procedure.note",
|
|
@@ -353,7 +353,7 @@
|
|
|
353
353
|
{
|
|
354
354
|
"id": "procedure.production-stage-files",
|
|
355
355
|
"path": "resources/procedures/production-stage-files.md",
|
|
356
|
-
"digest": "sha256:
|
|
356
|
+
"digest": "sha256:a057e59b37546f1ab5f2c70c9ac8b5922382931949643c20450aac00ac744da8"
|
|
357
357
|
},
|
|
358
358
|
{
|
|
359
359
|
"id": "procedure.project-configuration",
|
|
@@ -388,7 +388,7 @@
|
|
|
388
388
|
{
|
|
389
389
|
"id": "procedure.source-update",
|
|
390
390
|
"path": "resources/procedures/source-update.md",
|
|
391
|
-
"digest": "sha256:
|
|
391
|
+
"digest": "sha256:992cfc2279fa770e7242d78b9a3d54989dd61262d495f2fda4cb260856da5151"
|
|
392
392
|
},
|
|
393
393
|
{
|
|
394
394
|
"id": "procedure.task-recovery",
|
|
@@ -598,7 +598,7 @@
|
|
|
598
598
|
},
|
|
599
599
|
{
|
|
600
600
|
"path": "provider.yaml",
|
|
601
|
-
"digest": "sha256:
|
|
601
|
+
"digest": "sha256:9a7308ff7ab4a2432a8bf5c969774c103162da96c9340511abfd3e1e2ee00f57"
|
|
602
602
|
},
|
|
603
603
|
{
|
|
604
604
|
"path": "resources/contracts/indexer-provider-guide.yaml",
|
|
@@ -646,7 +646,7 @@
|
|
|
646
646
|
},
|
|
647
647
|
{
|
|
648
648
|
"path": "resources/manuals/guides/code-indexer-skill-authoring.md",
|
|
649
|
-
"digest": "sha256:
|
|
649
|
+
"digest": "sha256:8d8bac9c302d969d518c99eeb7a98532d7499c7bac6dc5bb85d5031d2948f50b"
|
|
650
650
|
},
|
|
651
651
|
{
|
|
652
652
|
"path": "resources/manuals/guides/imports.md",
|
|
@@ -658,7 +658,7 @@
|
|
|
658
658
|
},
|
|
659
659
|
{
|
|
660
660
|
"path": "resources/manuals/guides/knowledge-updates.md",
|
|
661
|
-
"digest": "sha256:
|
|
661
|
+
"digest": "sha256:0ccba0d285484040bd5fb513081e5c734b63debd86a34ee5c38f692f4537be07"
|
|
662
662
|
},
|
|
663
663
|
{
|
|
664
664
|
"path": "resources/manuals/guides/lark-resources.md",
|
|
@@ -666,7 +666,7 @@
|
|
|
666
666
|
},
|
|
667
667
|
{
|
|
668
668
|
"path": "resources/manuals/guides/markdown-indexer-skill-authoring.md",
|
|
669
|
-
"digest": "sha256:
|
|
669
|
+
"digest": "sha256:9dcfd99cd0c999e04c15d92fafeb9c740c931dd547825622ae76032cfdd3e2fc"
|
|
670
670
|
},
|
|
671
671
|
{
|
|
672
672
|
"path": "resources/manuals/guides/note.md",
|
|
@@ -714,7 +714,7 @@
|
|
|
714
714
|
},
|
|
715
715
|
{
|
|
716
716
|
"path": "resources/manuals/reference/package-templates.md",
|
|
717
|
-
"digest": "sha256:
|
|
717
|
+
"digest": "sha256:801a6bea36673decab62367f38a1d31b9c7555b7df67e30e9312b51412510c78"
|
|
718
718
|
},
|
|
719
719
|
{
|
|
720
720
|
"path": "resources/manuals/reference/project-api.md",
|
|
@@ -726,7 +726,7 @@
|
|
|
726
726
|
},
|
|
727
727
|
{
|
|
728
728
|
"path": "resources/procedures/approved-revision.md",
|
|
729
|
-
"digest": "sha256:
|
|
729
|
+
"digest": "sha256:53e905cc5e189094b90bda7cccaa7d3e2bf7151e59bd3f06a44d7fb966aef33d"
|
|
730
730
|
},
|
|
731
731
|
{
|
|
732
732
|
"path": "resources/procedures/close-and-build.md",
|
|
@@ -746,15 +746,15 @@
|
|
|
746
746
|
},
|
|
747
747
|
{
|
|
748
748
|
"path": "resources/procedures/knowledge-maintenance.md",
|
|
749
|
-
"digest": "sha256:
|
|
749
|
+
"digest": "sha256:e149feae8c33bf5f9859b14e119991fa76b7a91e3916bcb2ffe04fcf064d9a60"
|
|
750
750
|
},
|
|
751
751
|
{
|
|
752
752
|
"path": "resources/procedures/knowledge-review.md",
|
|
753
|
-
"digest": "sha256:
|
|
753
|
+
"digest": "sha256:bc8e0de7d9a94480b21373074bb18deb50ab532327e18bb734cc762afa5e09dd"
|
|
754
754
|
},
|
|
755
755
|
{
|
|
756
756
|
"path": "resources/procedures/knowledge-updates.md",
|
|
757
|
-
"digest": "sha256:
|
|
757
|
+
"digest": "sha256:a85f755b29c88c8392da42b0b4b4223f523ca01417c4142284c1a5f43c8d5db1"
|
|
758
758
|
},
|
|
759
759
|
{
|
|
760
760
|
"path": "resources/procedures/note.md",
|
|
@@ -774,7 +774,7 @@
|
|
|
774
774
|
},
|
|
775
775
|
{
|
|
776
776
|
"path": "resources/procedures/production-stage-files.md",
|
|
777
|
-
"digest": "sha256:
|
|
777
|
+
"digest": "sha256:a057e59b37546f1ab5f2c70c9ac8b5922382931949643c20450aac00ac744da8"
|
|
778
778
|
},
|
|
779
779
|
{
|
|
780
780
|
"path": "resources/procedures/project-configuration.md",
|
|
@@ -802,7 +802,7 @@
|
|
|
802
802
|
},
|
|
803
803
|
{
|
|
804
804
|
"path": "resources/procedures/source-update.md",
|
|
805
|
-
"digest": "sha256:
|
|
805
|
+
"digest": "sha256:992cfc2279fa770e7242d78b9a3d54989dd61262d495f2fda4cb260856da5151"
|
|
806
806
|
},
|
|
807
807
|
{
|
|
808
808
|
"path": "resources/procedures/task-recovery.md",
|
|
@@ -902,7 +902,7 @@
|
|
|
902
902
|
},
|
|
903
903
|
{
|
|
904
904
|
"path": "skills/run-indexer-agent-step/SKILL.md",
|
|
905
|
-
"digest": "sha256:
|
|
905
|
+
"digest": "sha256:d86e5592df9a96ce7a0c54ce6f4b310df21df16cb521fb5aaadcc21eb90020a8"
|
|
906
906
|
},
|
|
907
907
|
{
|
|
908
908
|
"path": "skills/run-indexer-lifecycle/SKILL.md",
|
|
@@ -910,7 +910,7 @@
|
|
|
910
910
|
},
|
|
911
911
|
{
|
|
912
912
|
"path": "skills/translate-site-locales/SKILL.md",
|
|
913
|
-
"digest": "sha256:
|
|
913
|
+
"digest": "sha256:e7bcb9e068ba91531c8948901fb1d505848e8ab941440a8a4e08bc61df280af7"
|
|
914
914
|
},
|
|
915
915
|
{
|
|
916
916
|
"path": "skills/work-production-stage/SKILL.md",
|
|
@@ -921,5 +921,5 @@
|
|
|
921
921
|
"indexer": [],
|
|
922
922
|
"workspace": []
|
|
923
923
|
},
|
|
924
|
-
"digest": "sha256:
|
|
924
|
+
"digest": "sha256:4aa7f4327d55e41e448a169562ce3275bc058cd2a678b5c191313a48d9f071df"
|
|
925
925
|
}
|
|
@@ -50,7 +50,7 @@ proof of runtime behavior. Preserve expressions without executing project code,
|
|
|
50
50
|
distinguish declaration defaults from implementation defaults, and state unknowns.
|
|
51
51
|
|
|
52
52
|
Use the current stage's Markdown and reference-file schemas. Each fragment cites
|
|
53
|
-
actual source regions from at most
|
|
53
|
+
actual source regions from at most five files (up to eight regions); the CLI
|
|
54
54
|
computes regional digests. Split
|
|
55
55
|
an explanation when it needs separate evidence, not to fill a fixed template.
|
|
56
56
|
Reuse stable article and fragment identities when revising. Supporting documents,
|
|
@@ -344,7 +344,7 @@ changing structure, adding a page or when a section has no unambiguous ID.
|
|
|
344
344
|
To change a fragment's citations, include `references` alongside its `section_id`:
|
|
345
345
|
each entry supplies `source_ref` and `locator` (`path`, `start_line`, `end_line`).
|
|
346
346
|
Context computes the region fingerprint. This uses the same revision submission,
|
|
347
|
-
with at most
|
|
347
|
+
with at most five source files and eight regions per fragment. Full Markdown may include a
|
|
348
348
|
`sections` list of reference edits; local section edits may change content,
|
|
349
349
|
references, or both. Omission preserves citations; an empty list removes them.
|
|
350
350
|
|
|
@@ -663,8 +663,17 @@ page-level incoming Markdown links to explicit replacements, and rebinds page
|
|
|
663
663
|
navigation or removes retired navigation targets while retaining groups.
|
|
664
664
|
Repair fragment links explicitly first: the CLI cannot infer where a split moved
|
|
665
665
|
a paragraph. Without a replacement, repair incoming links before applying.
|
|
666
|
-
|
|
667
|
-
|
|
666
|
+
While a revision batch is active and not yet approved, the same command schedules
|
|
667
|
+
the retirement in that batch instead. Its preview lists the follow-up by the entry
|
|
668
|
+
that handles it: pages whose links to the retired page need updating (they join
|
|
669
|
+
the batch), navigation entries that will point to the replacement and keep their
|
|
670
|
+
label or be removed (adjust labels with `context task adjust` if needed), and
|
|
671
|
+
translations that become orphaned (the translation step removes them). The
|
|
672
|
+
retired page's own unfinished draft is dropped; the replacement may be a page new
|
|
673
|
+
in this batch. Nothing is deleted until the batch's final Review apply, which
|
|
674
|
+
computes the retirement on the final drafts in the same write as the approved
|
|
675
|
+
pages. Once a batch is approved, finish its delivery first; unfinished production
|
|
676
|
+
targeting a selected page must be finished or amended rather than discarded.
|
|
668
677
|
|
|
669
678
|
Follow status and the normal close/version/build flow before delivery. Sources
|
|
670
679
|
and shared assets are not deleted. The response provides a temporary restore
|
|
@@ -688,7 +697,11 @@ approved-page revision or source-update queue. Keep `scopes` and `instruction`
|
|
|
688
697
|
explicit. First call without `refresh`; it authorizes replacing only those
|
|
689
698
|
inputs and blocks page completion while acquisition is pending. Import the
|
|
690
699
|
selected new material, then repeat with `refresh: true` to bind the actual local
|
|
691
|
-
versions and obtain the new Route.
|
|
700
|
+
versions and obtain the new Route. When every selected source is newly added to
|
|
701
|
+
the task and its material is already local (an imported document, or a repository
|
|
702
|
+
at the commit the delivered knowledge already uses), the first call completes the
|
|
703
|
+
adjustment and returns `adjusted` with `acquisition: already-available`; do not
|
|
704
|
+
repeat it. Do not submit the old revision. Current
|
|
692
705
|
prose and queued pages remain; an affected draft returns to writing/review.
|
|
693
706
|
An unrelated queued page does not revoke an unchanged current page's review.
|
|
694
707
|
If a page has already been applied, finish its close/build before changing its
|
|
@@ -717,7 +730,7 @@ Revision section edits may supply `references` as `source_ref` plus a
|
|
|
717
730
|
`locator` containing `path`, `start_line`, and `end_line`. Context computes the
|
|
718
731
|
regional digest. Omitted references preserve the current fragment's citations;
|
|
719
732
|
an explicit empty list removes them, and deleting a fragment removes its
|
|
720
|
-
citations. Each fragment may cite at most
|
|
733
|
+
citations. Each fragment may cite at most five source files and eight regions. Register and
|
|
721
734
|
authorize new material before citing it, then follow normal Review, close and
|
|
722
735
|
build. Article links alone do not authorize reading new sources or prove a claim.
|
|
723
736
|
|
|
@@ -731,5 +744,5 @@ same-level or higher-level heading. A quote is an exact, unique, nonempty
|
|
|
731
744
|
substring (line endings are normalized). Ambiguous matches return candidate
|
|
732
745
|
line ranges. Both forms resolve against authorized captured text before hashing;
|
|
733
746
|
stored references still contain only `path`, `start_line` and `end_line`.
|
|
734
|
-
The per-fragment limits (
|
|
747
|
+
The per-fragment limits (five source files, eight regions) apply after
|
|
735
748
|
resolving and deduplicating positions.
|
|
@@ -45,7 +45,7 @@ submit the short stage-relative manifest. Title and description belong to the
|
|
|
45
45
|
article, not an internal layout-mapping tuple.
|
|
46
46
|
|
|
47
47
|
Keep stable article and fragment identities when revising. Each fragment cites
|
|
48
|
-
actual source regions from at most
|
|
48
|
+
actual source regions from at most five files (up to eight regions). The CLI handles source digests and safety;
|
|
49
49
|
the Agent judges whether the evidence supports the explanation. For a local
|
|
50
50
|
failure, use the returned fragment identifier or position to repair the affected
|
|
51
51
|
part. Completed independent tasks can be submitted without the rest of the batch.
|
|
@@ -330,7 +330,7 @@ Approved Markdown under `knowledge/` and the article index in
|
|
|
330
330
|
- Markdown fragment markers contain only their stable ID:
|
|
331
331
|
`<!-- context:section id="usage" -->` and `<!-- /context:section -->`.
|
|
332
332
|
Structure records each corresponding ID and its source positions: at most
|
|
333
|
-
|
|
333
|
+
five distinct source files and eight regions per fragment, not per article.
|
|
334
334
|
- A reference contains `source_ref`, `locator: { path, start_line, end_line }`
|
|
335
335
|
and the Host-computed regional `content_digest`. Do not duplicate this in
|
|
336
336
|
Markdown frontmatter or comments.
|
|
@@ -30,8 +30,9 @@ A `requirement_ref` alone does not authorize it: the selected requirement in
|
|
|
30
30
|
`src/indexers.yaml` must connect the new source to an existing task source through
|
|
31
31
|
its target or evidence scopes. When `revision-source-scope-unconfirmed` is returned,
|
|
32
32
|
use its `missing` and `configuration` fields to correct only the user-authorized
|
|
33
|
-
association. Then retry the same `task adjust` without refresh
|
|
34
|
-
|
|
33
|
+
association. Then retry the same `task adjust` without refresh. If it returns
|
|
34
|
+
`adjusted` (the material was already local), continue; otherwise, once material
|
|
35
|
+
is available, repeat with `refresh: true`. Reread the resulting revision. Do not invent
|
|
35
36
|
module references, replace an older note, delete sources or clear the task to
|
|
36
37
|
satisfy this boundary. Already imported material does not need to be imported again.
|
|
37
38
|
The adjusted source stays citable by the remaining pages queued in the same revision;
|
|
@@ -139,13 +140,18 @@ Action schema and the same source and baseline validation.
|
|
|
139
140
|
|
|
140
141
|
When a fragment's support changes, include `references` with its actual
|
|
141
142
|
`source_ref` and `locator` (`path`, `start_line`, `end_line`). Each fragment allows
|
|
142
|
-
regions from up to
|
|
143
|
+
regions from up to five source files, eight regions in total; Context reads the captured region and computes its digest.
|
|
143
144
|
For full Markdown, optional `sections` contains only `{ section_id, references }`
|
|
144
145
|
entries; for local edits it can accompany `content` or update references alone.
|
|
145
146
|
An explicit empty list removes that fragment's citations. Deleted fragments lose
|
|
146
147
|
their references; new fragments need their own selected sources, not copied IDs.
|
|
147
148
|
Uniquely moved unchanged text can retain its fingerprint at its new position;
|
|
148
149
|
changed or ambiguous regions remain visible for review, not silently refreshed.
|
|
150
|
+
Inside a submitted `references` list, an earlier citation repeated with the same
|
|
151
|
+
`start_line`/`end_line` means "keep that evidence": Context moves it to where that
|
|
152
|
+
text is now, or rejects the fragment when it no longer exists uniquely. To cite
|
|
153
|
+
the text now at those lines instead, use a `quote` or `heading` locator; those
|
|
154
|
+
always select current text.
|
|
149
155
|
|
|
150
156
|
For example, after substituting IDs/tokens from this Route:
|
|
151
157
|
|
|
@@ -158,6 +164,15 @@ same command: it returns the assembled Markdown and prior text without accepting
|
|
|
158
164
|
or advancing the revision. Submit without `--preview` after checking it. Preview
|
|
159
165
|
is optional; it does not replace Review or authorize a stale revision.
|
|
160
166
|
|
|
167
|
+
For a prepared multi-page batch (`prepare-current`), append `--preview` to the
|
|
168
|
+
batch submission. It applies the submission checks to every page against its
|
|
169
|
+
issued input (task binding, fragment file and region limits, line ranges in the
|
|
170
|
+
fixed source, signing) against the current Route and returns one result per page
|
|
171
|
+
with its issues, without saving drafts, task state or source caches. It reports problems and never repairs them: for example, a line range
|
|
172
|
+
past the end of a file is reported, not clamped. Write the whole batch, preview
|
|
173
|
+
it once, correct the flagged pages, then submit; do not write ad-hoc validation
|
|
174
|
+
or re-signing scripts.
|
|
175
|
+
|
|
161
176
|
Preview is useful only when its assembled text will be read before deciding to
|
|
162
177
|
submit. An unattended loop submits directly. Continue from the receipt's
|
|
163
178
|
`next_route.inline`, or read `next_route.file` once; do not routinely run status
|
|
@@ -193,7 +208,7 @@ same-level or higher-level heading. A quote is an exact, unique, nonempty
|
|
|
193
208
|
substring (line endings are normalized). Ambiguous matches return candidate
|
|
194
209
|
line ranges. Both forms resolve against authorized captured text before hashing;
|
|
195
210
|
stored references still contain only `path`, `start_line` and `end_line`.
|
|
196
|
-
The per-fragment limits (
|
|
211
|
+
The per-fragment limits (five source files, eight regions) apply after
|
|
197
212
|
resolving and deduplicating positions.
|
|
198
213
|
|
|
199
214
|
## Submitting several prewritten pages
|
|
@@ -44,6 +44,22 @@ adjustment procedures. A regenerated table does not advance a whole-source
|
|
|
44
44
|
processed baseline. A changed upstream version still requires source impact
|
|
45
45
|
assessment, including other affected approved pages and new topics.
|
|
46
46
|
|
|
47
|
+
While the current revision batch (a maintenance batch or the pages of a source
|
|
48
|
+
update) is not yet approved, a page request joins it instead of queueing: the
|
|
49
|
+
result says `joined-current-batch`, the page enters this batch's Review, and a
|
|
50
|
+
request for a page already drafted here restarts from that draft. Once Review
|
|
51
|
+
approves the batch, new requests queue for the next batch. A new source update
|
|
52
|
+
never joins; it starts its own batch. Translation and version recording wait
|
|
53
|
+
until no request is queued, so they run once after the last batch.
|
|
54
|
+
|
|
55
|
+
After approval and before delivery finishes, a mechanical correction caused by
|
|
56
|
+
the revision (a broken link, link text pointing to a retired page, a menu label,
|
|
57
|
+
an anchor or formatting) may be applied to the approved page without another
|
|
58
|
+
Review. You judge whether it is mechanical; if it changes meaning or citations,
|
|
59
|
+
register it for the next batch. Record each one with
|
|
60
|
+
`context task record-fix --input <{path, reason}> --format json` and report the
|
|
61
|
+
recorded fixes to the user with the batch result.
|
|
62
|
+
|
|
47
63
|
`after-batch` waits for the current delivery boundary. Use `priority` when the
|
|
48
64
|
user asks to handle the correction first: the Graph requests early delivery
|
|
49
65
|
of complete pages, retaining ordinary Review gates. Never interrupt a running
|