@c4a/context-cli 0.7.106 → 0.7.107
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/cli.js +2261 -1399
- package/indexers/contracts/profile-contract.json +245 -245
- package/indexers/release-manifest.json +1 -1
- package/package.json +12 -12
- package/plugins/VERSION +1 -1
- package/plugins/claude/.claude-plugin/plugin.json +1 -1
- package/plugins/claude/commands/context.md +11 -1
- package/plugins/claude/resources/context/routine-update.md +10 -2
- package/plugins/codex/.codex-plugin/plugin.json +2 -2
- package/plugins/codex/skills/context/SKILL.md +11 -1
- package/plugins/codex/skills/context/references/routine-update.md +10 -2
- package/plugins/cursor/.cursor-plugin/plugin.json +1 -1
- package/plugins/cursor/commands/c4a-context.md +11 -1
- package/plugins/cursor/resources/context/routine-update.md +10 -2
- package/plugins/skills/context/SKILL.md +11 -1
- package/plugins/skills/context/references/routine-update.md +10 -2
- package/providers/context/manifest.json +8 -8
- package/providers/context/provider.yaml +1 -1
- package/providers/context/resources/manuals/guides/knowledge-updates.md +71 -0
- package/providers/context/resources/procedures/knowledge-updates.md +71 -0
- package/providers/context/resources/procedures/source-update.md +6 -0
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@c4a/context-cli",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.107",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "Local runtime and Agent integration for traceable knowledge production",
|
|
6
6
|
"license": "MIT",
|
|
@@ -24,17 +24,17 @@
|
|
|
24
24
|
},
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@c4a/agent-graph": "0.3.0",
|
|
27
|
-
"@c4a/context": "0.7.
|
|
28
|
-
"@c4a/extract": "0.7.
|
|
29
|
-
"@c4a/extract-contract": "0.7.
|
|
30
|
-
"@c4a/extract-go": "0.7.
|
|
31
|
-
"@c4a/extract-mdx": "0.7.
|
|
32
|
-
"@c4a/extract-proto": "0.7.
|
|
33
|
-
"@c4a/extract-rush": "0.7.
|
|
34
|
-
"@c4a/extract-sql": "0.7.
|
|
35
|
-
"@c4a/extract-style": "0.7.
|
|
36
|
-
"@c4a/extract-thrift": "0.7.
|
|
37
|
-
"@c4a/extract-ts": "0.7.
|
|
27
|
+
"@c4a/context": "0.7.107",
|
|
28
|
+
"@c4a/extract": "0.7.107",
|
|
29
|
+
"@c4a/extract-contract": "0.7.107",
|
|
30
|
+
"@c4a/extract-go": "0.7.107",
|
|
31
|
+
"@c4a/extract-mdx": "0.7.107",
|
|
32
|
+
"@c4a/extract-proto": "0.7.107",
|
|
33
|
+
"@c4a/extract-rush": "0.7.107",
|
|
34
|
+
"@c4a/extract-sql": "0.7.107",
|
|
35
|
+
"@c4a/extract-style": "0.7.107",
|
|
36
|
+
"@c4a/extract-thrift": "0.7.107",
|
|
37
|
+
"@c4a/extract-ts": "0.7.107",
|
|
38
38
|
"@mermaid-js/layout-elk": "0.2.0",
|
|
39
39
|
"commander": "^11.0.0",
|
|
40
40
|
"d3-force": "3.0.0",
|
package/plugins/VERSION
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
0.7.
|
|
1
|
+
0.7.107
|
|
@@ -144,7 +144,7 @@ without the user's authorization.
|
|
|
144
144
|
|
|
145
145
|
### Check the CLI first
|
|
146
146
|
|
|
147
|
-
This Skill ships with Context 0.7.
|
|
147
|
+
This Skill ships with Context 0.7.107.
|
|
148
148
|
|
|
149
149
|
When entering production in a workspace, align the CLI, this Skill and the
|
|
150
150
|
workspace SDK once per session with [version alignment](../resources/context/version-alignment.md):
|
|
@@ -516,6 +516,16 @@ follow its private-install recovery. Keep `CONTEXT_LARK_CLI_BIN` pointing to tha
|
|
|
516
516
|
private executable on subsequent Context commands that access Lark; do not
|
|
517
517
|
upgrade or replace the host's global `lark-cli`.
|
|
518
518
|
|
|
519
|
+
Repository sources are read from local checkouts unless `CONTEXT_SOURCE_MODE`
|
|
520
|
+
(or `--source-mode`) is `remote` or `auto`; pass the mode the user or host
|
|
521
|
+
configuration sets to every Context command. A source shown as `access: remote`
|
|
522
|
+
needs no clone for updates, revisions or verification: read its code through
|
|
523
|
+
the Sourcegraph MCP tools at the registered commit. When a command returns
|
|
524
|
+
`next_action.mcp_tool: authorize_cli`, call that tool with `client: "context"`
|
|
525
|
+
once and run the returned `command` with its `code` and `host`; never print the
|
|
526
|
+
token. New pages and code parsing still need a local checkout. The
|
|
527
|
+
knowledge-updates guide, "Update without cloning", has the details.
|
|
528
|
+
|
|
519
529
|
### Continue
|
|
520
530
|
|
|
521
531
|
Use `next_route.inline` as the complete Route when present. Read
|
|
@@ -73,7 +73,11 @@ workspace targets or the delivery configuration.
|
|
|
73
73
|
with [version alignment](version-alignment.md). Enter the workspace named by
|
|
74
74
|
the host configuration before the entry, cloning it when the current
|
|
75
75
|
directory does not have it; never initialize a new workspace for a routine
|
|
76
|
-
run, and report a missing or unconfigured workspace instead.
|
|
76
|
+
run, and report a missing or unconfigured workspace instead. Run every
|
|
77
|
+
Context command with the `CONTEXT_SOURCE_MODE` the host configuration sets
|
|
78
|
+
(`local` when unset). With `remote` or `auto`, a repository `context status`
|
|
79
|
+
reports as `access: remote` is read from Sourcegraph and needs no clone (the
|
|
80
|
+
knowledge-updates guide, "Update without cloning"). Clone any other missing
|
|
77
81
|
registered repository (shallow or partial for large ones), then update the
|
|
78
82
|
workspace branch from its remote. Never discard local work.
|
|
79
83
|
2. **Resume first.** If `context status` shows an unfinished task, finish it (use
|
|
@@ -110,7 +114,9 @@ workspace targets or the delivery configuration.
|
|
|
110
114
|
knowledge-updates guide, "Refresh several registered sources", step 4):
|
|
111
115
|
1. Fetch and check out each of the batch's repositories at its new commit in
|
|
112
116
|
a shallow or partial clone, keeping the processed commit available:
|
|
113
|
-
`--input` reads only what the checkout already has.
|
|
117
|
+
`--input` reads only what the checkout already has. Skip this for a
|
|
118
|
+
repository read from Sourcegraph; size its change with the Sourcegraph
|
|
119
|
+
diff instead.
|
|
114
120
|
2. Move only the batch's registrations: rerun `context source add repo` with
|
|
115
121
|
the registered namespace, `--module`, remote or local path and subpath,
|
|
116
122
|
changing only `--ref <sha>`.
|
|
@@ -187,6 +193,8 @@ workspace targets or the delivery configuration.
|
|
|
187
193
|
| CLI missing or below the host minimum | Install or upgrade once as the entry Skill describes |
|
|
188
194
|
| Previous run left a task or PLAN | Resume it; never reset or plan again |
|
|
189
195
|
| Repository or document unreadable | Record a gap, continue with the rest |
|
|
196
|
+
| A command returns `next_action.mcp_tool: authorize_cli` | Call that Sourcegraph MCP tool with `client: "context"` once, run the returned `command` with its `code` and `host`, then rerun the command; on `TEMPORARY_TOKEN_LIMIT` run `context source sourcegraph-auth --refused TEMPORARY_TOKEN_LIMIT` and continue without remote reads |
|
|
197
|
+
| The update lists `skipped_sources` | Those repositories keep their processed versions; report each reason and step, and continue with the rest |
|
|
190
198
|
| Update stops because cited file contents are not downloaded (`source-content-missing`) | Make them available in the checkout in whatever way suits the environment, such as fetching, checking out the commit or cloning again, then rerun the update |
|
|
191
199
|
| Review finds fixable problems | Fix the drafts and review again under delegation |
|
|
192
200
|
| Remote moved during merge | Rebase; re-inspect against the remote commit and record the version again |
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "c4a",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.107",
|
|
4
4
|
"description": "Start or continue a project-local knowledge workspace through one graph-routed entry.",
|
|
5
5
|
"author": { "name": "c4a" },
|
|
6
6
|
"homepage": "https://github.com/context4ai/c4a",
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"skills": "./skills/",
|
|
11
11
|
"interface": {
|
|
12
12
|
"displayName": "C4A Context",
|
|
13
|
-
"shortDescription": "Initialize and advance a local, source-linked project knowledge workspace.\nv0.7.
|
|
13
|
+
"shortDescription": "Initialize and advance a local, source-linked project knowledge workspace.\nv0.7.107",
|
|
14
14
|
"longDescription": "Create a Context workspace and use agent-guided next steps to register sources, run extraction, review candidates, build package outputs, and verify health without silently mutating source repositories.",
|
|
15
15
|
"developerName": "c4a",
|
|
16
16
|
"category": "Productivity",
|
|
@@ -142,7 +142,7 @@ without the user's authorization.
|
|
|
142
142
|
|
|
143
143
|
### Check the CLI first
|
|
144
144
|
|
|
145
|
-
This Skill ships with Context 0.7.
|
|
145
|
+
This Skill ships with Context 0.7.107.
|
|
146
146
|
|
|
147
147
|
When entering production in a workspace, align the CLI, this Skill and the
|
|
148
148
|
workspace SDK once per session with [version alignment](references/version-alignment.md):
|
|
@@ -514,6 +514,16 @@ follow its private-install recovery. Keep `CONTEXT_LARK_CLI_BIN` pointing to tha
|
|
|
514
514
|
private executable on subsequent Context commands that access Lark; do not
|
|
515
515
|
upgrade or replace the host's global `lark-cli`.
|
|
516
516
|
|
|
517
|
+
Repository sources are read from local checkouts unless `CONTEXT_SOURCE_MODE`
|
|
518
|
+
(or `--source-mode`) is `remote` or `auto`; pass the mode the user or host
|
|
519
|
+
configuration sets to every Context command. A source shown as `access: remote`
|
|
520
|
+
needs no clone for updates, revisions or verification: read its code through
|
|
521
|
+
the Sourcegraph MCP tools at the registered commit. When a command returns
|
|
522
|
+
`next_action.mcp_tool: authorize_cli`, call that tool with `client: "context"`
|
|
523
|
+
once and run the returned `command` with its `code` and `host`; never print the
|
|
524
|
+
token. New pages and code parsing still need a local checkout. The
|
|
525
|
+
knowledge-updates guide, "Update without cloning", has the details.
|
|
526
|
+
|
|
517
527
|
### Continue
|
|
518
528
|
|
|
519
529
|
Use `next_route.inline` as the complete Route when present. Read
|
|
@@ -73,7 +73,11 @@ workspace targets or the delivery configuration.
|
|
|
73
73
|
with [version alignment](version-alignment.md). Enter the workspace named by
|
|
74
74
|
the host configuration before the entry, cloning it when the current
|
|
75
75
|
directory does not have it; never initialize a new workspace for a routine
|
|
76
|
-
run, and report a missing or unconfigured workspace instead.
|
|
76
|
+
run, and report a missing or unconfigured workspace instead. Run every
|
|
77
|
+
Context command with the `CONTEXT_SOURCE_MODE` the host configuration sets
|
|
78
|
+
(`local` when unset). With `remote` or `auto`, a repository `context status`
|
|
79
|
+
reports as `access: remote` is read from Sourcegraph and needs no clone (the
|
|
80
|
+
knowledge-updates guide, "Update without cloning"). Clone any other missing
|
|
77
81
|
registered repository (shallow or partial for large ones), then update the
|
|
78
82
|
workspace branch from its remote. Never discard local work.
|
|
79
83
|
2. **Resume first.** If `context status` shows an unfinished task, finish it (use
|
|
@@ -110,7 +114,9 @@ workspace targets or the delivery configuration.
|
|
|
110
114
|
knowledge-updates guide, "Refresh several registered sources", step 4):
|
|
111
115
|
1. Fetch and check out each of the batch's repositories at its new commit in
|
|
112
116
|
a shallow or partial clone, keeping the processed commit available:
|
|
113
|
-
`--input` reads only what the checkout already has.
|
|
117
|
+
`--input` reads only what the checkout already has. Skip this for a
|
|
118
|
+
repository read from Sourcegraph; size its change with the Sourcegraph
|
|
119
|
+
diff instead.
|
|
114
120
|
2. Move only the batch's registrations: rerun `context source add repo` with
|
|
115
121
|
the registered namespace, `--module`, remote or local path and subpath,
|
|
116
122
|
changing only `--ref <sha>`.
|
|
@@ -187,6 +193,8 @@ workspace targets or the delivery configuration.
|
|
|
187
193
|
| CLI missing or below the host minimum | Install or upgrade once as the entry Skill describes |
|
|
188
194
|
| Previous run left a task or PLAN | Resume it; never reset or plan again |
|
|
189
195
|
| Repository or document unreadable | Record a gap, continue with the rest |
|
|
196
|
+
| A command returns `next_action.mcp_tool: authorize_cli` | Call that Sourcegraph MCP tool with `client: "context"` once, run the returned `command` with its `code` and `host`, then rerun the command; on `TEMPORARY_TOKEN_LIMIT` run `context source sourcegraph-auth --refused TEMPORARY_TOKEN_LIMIT` and continue without remote reads |
|
|
197
|
+
| The update lists `skipped_sources` | Those repositories keep their processed versions; report each reason and step, and continue with the rest |
|
|
190
198
|
| Update stops because cited file contents are not downloaded (`source-content-missing`) | Make them available in the checkout in whatever way suits the environment, such as fetching, checking out the commit or cloning again, then rerun the update |
|
|
191
199
|
| Review finds fixable problems | Fix the drafts and review again under delegation |
|
|
192
200
|
| Remote moved during merge | Rebase; re-inspect against the remote commit and record the version again |
|
|
@@ -139,7 +139,7 @@ without the user's authorization.
|
|
|
139
139
|
|
|
140
140
|
### Check the CLI first
|
|
141
141
|
|
|
142
|
-
This Skill ships with Context 0.7.
|
|
142
|
+
This Skill ships with Context 0.7.107.
|
|
143
143
|
|
|
144
144
|
When entering production in a workspace, align the CLI, this Skill and the
|
|
145
145
|
workspace SDK once per session with [version alignment](../resources/context/version-alignment.md):
|
|
@@ -511,6 +511,16 @@ follow its private-install recovery. Keep `CONTEXT_LARK_CLI_BIN` pointing to tha
|
|
|
511
511
|
private executable on subsequent Context commands that access Lark; do not
|
|
512
512
|
upgrade or replace the host's global `lark-cli`.
|
|
513
513
|
|
|
514
|
+
Repository sources are read from local checkouts unless `CONTEXT_SOURCE_MODE`
|
|
515
|
+
(or `--source-mode`) is `remote` or `auto`; pass the mode the user or host
|
|
516
|
+
configuration sets to every Context command. A source shown as `access: remote`
|
|
517
|
+
needs no clone for updates, revisions or verification: read its code through
|
|
518
|
+
the Sourcegraph MCP tools at the registered commit. When a command returns
|
|
519
|
+
`next_action.mcp_tool: authorize_cli`, call that tool with `client: "context"`
|
|
520
|
+
once and run the returned `command` with its `code` and `host`; never print the
|
|
521
|
+
token. New pages and code parsing still need a local checkout. The
|
|
522
|
+
knowledge-updates guide, "Update without cloning", has the details.
|
|
523
|
+
|
|
514
524
|
### Continue
|
|
515
525
|
|
|
516
526
|
Use `next_route.inline` as the complete Route when present. Read
|
|
@@ -73,7 +73,11 @@ workspace targets or the delivery configuration.
|
|
|
73
73
|
with [version alignment](version-alignment.md). Enter the workspace named by
|
|
74
74
|
the host configuration before the entry, cloning it when the current
|
|
75
75
|
directory does not have it; never initialize a new workspace for a routine
|
|
76
|
-
run, and report a missing or unconfigured workspace instead.
|
|
76
|
+
run, and report a missing or unconfigured workspace instead. Run every
|
|
77
|
+
Context command with the `CONTEXT_SOURCE_MODE` the host configuration sets
|
|
78
|
+
(`local` when unset). With `remote` or `auto`, a repository `context status`
|
|
79
|
+
reports as `access: remote` is read from Sourcegraph and needs no clone (the
|
|
80
|
+
knowledge-updates guide, "Update without cloning"). Clone any other missing
|
|
77
81
|
registered repository (shallow or partial for large ones), then update the
|
|
78
82
|
workspace branch from its remote. Never discard local work.
|
|
79
83
|
2. **Resume first.** If `context status` shows an unfinished task, finish it (use
|
|
@@ -110,7 +114,9 @@ workspace targets or the delivery configuration.
|
|
|
110
114
|
knowledge-updates guide, "Refresh several registered sources", step 4):
|
|
111
115
|
1. Fetch and check out each of the batch's repositories at its new commit in
|
|
112
116
|
a shallow or partial clone, keeping the processed commit available:
|
|
113
|
-
`--input` reads only what the checkout already has.
|
|
117
|
+
`--input` reads only what the checkout already has. Skip this for a
|
|
118
|
+
repository read from Sourcegraph; size its change with the Sourcegraph
|
|
119
|
+
diff instead.
|
|
114
120
|
2. Move only the batch's registrations: rerun `context source add repo` with
|
|
115
121
|
the registered namespace, `--module`, remote or local path and subpath,
|
|
116
122
|
changing only `--ref <sha>`.
|
|
@@ -187,6 +193,8 @@ workspace targets or the delivery configuration.
|
|
|
187
193
|
| CLI missing or below the host minimum | Install or upgrade once as the entry Skill describes |
|
|
188
194
|
| Previous run left a task or PLAN | Resume it; never reset or plan again |
|
|
189
195
|
| Repository or document unreadable | Record a gap, continue with the rest |
|
|
196
|
+
| A command returns `next_action.mcp_tool: authorize_cli` | Call that Sourcegraph MCP tool with `client: "context"` once, run the returned `command` with its `code` and `host`, then rerun the command; on `TEMPORARY_TOKEN_LIMIT` run `context source sourcegraph-auth --refused TEMPORARY_TOKEN_LIMIT` and continue without remote reads |
|
|
197
|
+
| The update lists `skipped_sources` | Those repositories keep their processed versions; report each reason and step, and continue with the rest |
|
|
190
198
|
| Update stops because cited file contents are not downloaded (`source-content-missing`) | Make them available in the checkout in whatever way suits the environment, such as fetching, checking out the commit or cloning again, then rerun the update |
|
|
191
199
|
| Review finds fixable problems | Fix the drafts and review again under delegation |
|
|
192
200
|
| Remote moved during merge | Rebase; re-inspect against the remote commit and record the version again |
|
|
@@ -142,7 +142,7 @@ without the user's authorization.
|
|
|
142
142
|
|
|
143
143
|
### Check the CLI first
|
|
144
144
|
|
|
145
|
-
This Skill ships with Context 0.7.
|
|
145
|
+
This Skill ships with Context 0.7.107.
|
|
146
146
|
|
|
147
147
|
When entering production in a workspace, align the CLI, this Skill and the
|
|
148
148
|
workspace SDK once per session with [version alignment](references/version-alignment.md):
|
|
@@ -514,6 +514,16 @@ follow its private-install recovery. Keep `CONTEXT_LARK_CLI_BIN` pointing to tha
|
|
|
514
514
|
private executable on subsequent Context commands that access Lark; do not
|
|
515
515
|
upgrade or replace the host's global `lark-cli`.
|
|
516
516
|
|
|
517
|
+
Repository sources are read from local checkouts unless `CONTEXT_SOURCE_MODE`
|
|
518
|
+
(or `--source-mode`) is `remote` or `auto`; pass the mode the user or host
|
|
519
|
+
configuration sets to every Context command. A source shown as `access: remote`
|
|
520
|
+
needs no clone for updates, revisions or verification: read its code through
|
|
521
|
+
the Sourcegraph MCP tools at the registered commit. When a command returns
|
|
522
|
+
`next_action.mcp_tool: authorize_cli`, call that tool with `client: "context"`
|
|
523
|
+
once and run the returned `command` with its `code` and `host`; never print the
|
|
524
|
+
token. New pages and code parsing still need a local checkout. The
|
|
525
|
+
knowledge-updates guide, "Update without cloning", has the details.
|
|
526
|
+
|
|
517
527
|
### Continue
|
|
518
528
|
|
|
519
529
|
Use `next_route.inline` as the complete Route when present. Read
|
|
@@ -73,7 +73,11 @@ workspace targets or the delivery configuration.
|
|
|
73
73
|
with [version alignment](version-alignment.md). Enter the workspace named by
|
|
74
74
|
the host configuration before the entry, cloning it when the current
|
|
75
75
|
directory does not have it; never initialize a new workspace for a routine
|
|
76
|
-
run, and report a missing or unconfigured workspace instead.
|
|
76
|
+
run, and report a missing or unconfigured workspace instead. Run every
|
|
77
|
+
Context command with the `CONTEXT_SOURCE_MODE` the host configuration sets
|
|
78
|
+
(`local` when unset). With `remote` or `auto`, a repository `context status`
|
|
79
|
+
reports as `access: remote` is read from Sourcegraph and needs no clone (the
|
|
80
|
+
knowledge-updates guide, "Update without cloning"). Clone any other missing
|
|
77
81
|
registered repository (shallow or partial for large ones), then update the
|
|
78
82
|
workspace branch from its remote. Never discard local work.
|
|
79
83
|
2. **Resume first.** If `context status` shows an unfinished task, finish it (use
|
|
@@ -110,7 +114,9 @@ workspace targets or the delivery configuration.
|
|
|
110
114
|
knowledge-updates guide, "Refresh several registered sources", step 4):
|
|
111
115
|
1. Fetch and check out each of the batch's repositories at its new commit in
|
|
112
116
|
a shallow or partial clone, keeping the processed commit available:
|
|
113
|
-
`--input` reads only what the checkout already has.
|
|
117
|
+
`--input` reads only what the checkout already has. Skip this for a
|
|
118
|
+
repository read from Sourcegraph; size its change with the Sourcegraph
|
|
119
|
+
diff instead.
|
|
114
120
|
2. Move only the batch's registrations: rerun `context source add repo` with
|
|
115
121
|
the registered namespace, `--module`, remote or local path and subpath,
|
|
116
122
|
changing only `--ref <sha>`.
|
|
@@ -187,6 +193,8 @@ workspace targets or the delivery configuration.
|
|
|
187
193
|
| CLI missing or below the host minimum | Install or upgrade once as the entry Skill describes |
|
|
188
194
|
| Previous run left a task or PLAN | Resume it; never reset or plan again |
|
|
189
195
|
| Repository or document unreadable | Record a gap, continue with the rest |
|
|
196
|
+
| A command returns `next_action.mcp_tool: authorize_cli` | Call that Sourcegraph MCP tool with `client: "context"` once, run the returned `command` with its `code` and `host`, then rerun the command; on `TEMPORARY_TOKEN_LIMIT` run `context source sourcegraph-auth --refused TEMPORARY_TOKEN_LIMIT` and continue without remote reads |
|
|
197
|
+
| The update lists `skipped_sources` | Those repositories keep their processed versions; report each reason and step, and continue with the rest |
|
|
190
198
|
| Update stops because cited file contents are not downloaded (`source-content-missing`) | Make them available in the checkout in whatever way suits the environment, such as fetching, checking out the commit or cloning again, then rerun the update |
|
|
191
199
|
| Review finds fixable problems | Fix the drafts and review again under delegation |
|
|
192
200
|
| Remote moved during merge | Rebase; re-inspect against the remote commit and record the version again |
|
|
@@ -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.107"
|
|
6
6
|
},
|
|
7
7
|
"providerManifest": "provider.yaml",
|
|
8
8
|
"graphs": [
|
|
@@ -328,7 +328,7 @@
|
|
|
328
328
|
{
|
|
329
329
|
"id": "procedure.knowledge-updates",
|
|
330
330
|
"path": "resources/procedures/knowledge-updates.md",
|
|
331
|
-
"digest": "sha256:
|
|
331
|
+
"digest": "sha256:ce2c33ef8ab66d04220eb455a3153b901cbc2bc9d3f1873fecf7651b386657b2"
|
|
332
332
|
},
|
|
333
333
|
{
|
|
334
334
|
"id": "procedure.note",
|
|
@@ -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:e0de1bbbdb08fb6dd38043e2d96e2d6b8e6c51231f0b16c5f1bb621224cfbda3"
|
|
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:4ff3ea3fa8ee460b99912ad7456cf6245df16764c6b80eac3a06016bb351a982"
|
|
602
602
|
},
|
|
603
603
|
{
|
|
604
604
|
"path": "resources/contracts/indexer-provider-guide.yaml",
|
|
@@ -658,7 +658,7 @@
|
|
|
658
658
|
},
|
|
659
659
|
{
|
|
660
660
|
"path": "resources/manuals/guides/knowledge-updates.md",
|
|
661
|
-
"digest": "sha256:
|
|
661
|
+
"digest": "sha256:8ac769f9f5130d152c05c7353536659b3e64bd087602502e2e71c4f51ae4e880"
|
|
662
662
|
},
|
|
663
663
|
{
|
|
664
664
|
"path": "resources/manuals/guides/lark-resources.md",
|
|
@@ -754,7 +754,7 @@
|
|
|
754
754
|
},
|
|
755
755
|
{
|
|
756
756
|
"path": "resources/procedures/knowledge-updates.md",
|
|
757
|
-
"digest": "sha256:
|
|
757
|
+
"digest": "sha256:ce2c33ef8ab66d04220eb455a3153b901cbc2bc9d3f1873fecf7651b386657b2"
|
|
758
758
|
},
|
|
759
759
|
{
|
|
760
760
|
"path": "resources/procedures/note.md",
|
|
@@ -802,7 +802,7 @@
|
|
|
802
802
|
},
|
|
803
803
|
{
|
|
804
804
|
"path": "resources/procedures/source-update.md",
|
|
805
|
-
"digest": "sha256:
|
|
805
|
+
"digest": "sha256:e0de1bbbdb08fb6dd38043e2d96e2d6b8e6c51231f0b16c5f1bb621224cfbda3"
|
|
806
806
|
},
|
|
807
807
|
{
|
|
808
808
|
"path": "resources/procedures/task-recovery.md",
|
|
@@ -921,5 +921,5 @@
|
|
|
921
921
|
"indexer": [],
|
|
922
922
|
"workspace": []
|
|
923
923
|
},
|
|
924
|
-
"digest": "sha256:
|
|
924
|
+
"digest": "sha256:ea176547125847c529283a51c9b35ebc9c03db40434ccac829b8cc33b885a0e3"
|
|
925
925
|
}
|
|
@@ -515,6 +515,77 @@ source-update decision, then leave `new_topics` empty, say in `scope_summary`
|
|
|
515
515
|
which uncited additions were left out, and put the rule into each revised
|
|
516
516
|
page's `instruction` so the writing step follows it.
|
|
517
517
|
|
|
518
|
+
## Update without cloning: read repositories through Sourcegraph
|
|
519
|
+
|
|
520
|
+
When a registered repository is also registered on a Sourcegraph site, Context
|
|
521
|
+
can read it over HTTP instead of from a checkout. Updates (`context update
|
|
522
|
+
--input` and `--pending`), revisions, submission checks, `verify` and `status`
|
|
523
|
+
then need no clone. The result is byte for byte the same: Context reads the raw
|
|
524
|
+
blob at the registered commit, checks it against its Git object id, and compares
|
|
525
|
+
commits with a names-only diff, so citations, `changed_references`, evidence
|
|
526
|
+
and `uncited_changes` match a local checkout. Writing new pages and parsing code
|
|
527
|
+
still need a local checkout, and so do `context source restore` and `ensure`.
|
|
528
|
+
|
|
529
|
+
Choose the mode with `CONTEXT_SOURCE_MODE` or `--source-mode` (the option wins):
|
|
530
|
+
|
|
531
|
+
| Mode | Behavior |
|
|
532
|
+
| --- | --- |
|
|
533
|
+
| `local` (default) | Checkouts only, exactly as before; Context sends no Sourcegraph request even when a site or token is configured. |
|
|
534
|
+
| `remote` | Every repository source is read from Sourcegraph. A repository it cannot serve is skipped: the update leaves that scope out (its processed version does not move), lists it in `skipped_sources` with the reason, and continues with the other scopes. |
|
|
535
|
+
| `auto` | Sourcegraph first, per repository; one the site cannot serve uses its local checkout, restored as usual when missing. Without a token, auto mode asks for authorization like remote mode instead of falling back. |
|
|
536
|
+
|
|
537
|
+
Sourcegraph can serve a repository when the site declares the remote-read
|
|
538
|
+
operations, the registered `git.remote` names the same code host and repository
|
|
539
|
+
as the Sourcegraph registration, one registered path group contains the whole
|
|
540
|
+
`subpath`, and the registered commit is readable. Commands that read remotely
|
|
541
|
+
say so: `context update` and `verify --format json` return `source_access`
|
|
542
|
+
(each repository's `access`, site, repository and commit, or the reason it was
|
|
543
|
+
skipped or read locally), and in `status` each such source has `access: remote`
|
|
544
|
+
instead of checkout advice. `ready` keeps describing the local checkout.
|
|
545
|
+
|
|
546
|
+
**Authorization.** The Sourcegraph MCP server the Agent already uses is the only
|
|
547
|
+
configuration needed. When a command needs a token and has none, it returns a
|
|
548
|
+
`next_action` with `mcp_tool: authorize_cli`, once, at top level
|
|
549
|
+
(`source_authorization`); sources waiting for it are listed with
|
|
550
|
+
`reason_code: sourcegraph-authorization-required` and need no clone. Call that MCP tool once with
|
|
551
|
+
`client: "context"`, then run
|
|
552
|
+
|
|
553
|
+
```bash
|
|
554
|
+
context source sourcegraph-auth --code <code> --host <host> --format json
|
|
555
|
+
```
|
|
556
|
+
|
|
557
|
+
with the returned one-time `code` and `host` (the site's API root). The CLI
|
|
558
|
+
exchanges the code for a temporary read-only token, keeps it in
|
|
559
|
+
`.tmp/context-runtime/sourcegraph/token.json` (mode 600, never committed) and
|
|
560
|
+
reuses it for later commands in this workspace. Authorize again only when a
|
|
561
|
+
command asks for it again: after the token expired unused, was revoked, or
|
|
562
|
+
reached its maximum lifetime. Never print, copy or log the token. If
|
|
563
|
+
`authorize_cli` answers `TEMPORARY_TOKEN_LIMIT`, do not retry; run `context
|
|
564
|
+
source sourcegraph-auth --refused TEMPORARY_TOKEN_LIMIT --format json`, after
|
|
565
|
+
which remote mode skips repository sources and auto mode reads checkouts until
|
|
566
|
+
earlier temporary tokens expire or are revoked in the Sourcegraph user
|
|
567
|
+
settings. On a development machine or in CI, `SOURCEGRAPH_URL` and
|
|
568
|
+
`SOURCEGRAPH_API_TOKEN` take precedence and need no authorization; Sourcegraph
|
|
569
|
+
CLI login configuration is not read.
|
|
570
|
+
|
|
571
|
+
**Versions.** Only the registered commit decides whether a repository can be
|
|
572
|
+
read. When it is not readable yet, `status`, `verify`, revisions and an explicit
|
|
573
|
+
`update --input` report it and change nothing; `context update --pending` asks
|
|
574
|
+
Sourcegraph to prepare its content (when the site allows), waits a bounded time
|
|
575
|
+
and otherwise reports the job and the next step. Rate limits and full quotas
|
|
576
|
+
are reported, never retried in a loop. When only the processed commit is no
|
|
577
|
+
longer readable, the update still runs: history evidence is `unavailable` and
|
|
578
|
+
`uncited_changes` reports the comparison as unknown, as with a shallow checkout.
|
|
579
|
+
A site that cannot list directories still groups uncited changes but marks no
|
|
580
|
+
`new_directory`, and says so in the entry's `note`.
|
|
581
|
+
|
|
582
|
+
**Reading for writing.** For a source the CLI reads from Sourcegraph, size the
|
|
583
|
+
change with the Sourcegraph diff of the processed and registered commits, and
|
|
584
|
+
read or search code through the Sourcegraph MCP tools pinned to the registered
|
|
585
|
+
full commit; do not clone it for the update. A source read locally, a new page
|
|
586
|
+
and code parsing follow the checkout steps above. A read failure in remote mode
|
|
587
|
+
is never a citation change: `verify` reports those citations as not checked.
|
|
588
|
+
|
|
518
589
|
## Versioned external content and archived collections
|
|
519
590
|
|
|
520
591
|
Published content that another team versions, such as a documentation
|
|
@@ -515,6 +515,77 @@ source-update decision, then leave `new_topics` empty, say in `scope_summary`
|
|
|
515
515
|
which uncited additions were left out, and put the rule into each revised
|
|
516
516
|
page's `instruction` so the writing step follows it.
|
|
517
517
|
|
|
518
|
+
## Update without cloning: read repositories through Sourcegraph
|
|
519
|
+
|
|
520
|
+
When a registered repository is also registered on a Sourcegraph site, Context
|
|
521
|
+
can read it over HTTP instead of from a checkout. Updates (`context update
|
|
522
|
+
--input` and `--pending`), revisions, submission checks, `verify` and `status`
|
|
523
|
+
then need no clone. The result is byte for byte the same: Context reads the raw
|
|
524
|
+
blob at the registered commit, checks it against its Git object id, and compares
|
|
525
|
+
commits with a names-only diff, so citations, `changed_references`, evidence
|
|
526
|
+
and `uncited_changes` match a local checkout. Writing new pages and parsing code
|
|
527
|
+
still need a local checkout, and so do `context source restore` and `ensure`.
|
|
528
|
+
|
|
529
|
+
Choose the mode with `CONTEXT_SOURCE_MODE` or `--source-mode` (the option wins):
|
|
530
|
+
|
|
531
|
+
| Mode | Behavior |
|
|
532
|
+
| --- | --- |
|
|
533
|
+
| `local` (default) | Checkouts only, exactly as before; Context sends no Sourcegraph request even when a site or token is configured. |
|
|
534
|
+
| `remote` | Every repository source is read from Sourcegraph. A repository it cannot serve is skipped: the update leaves that scope out (its processed version does not move), lists it in `skipped_sources` with the reason, and continues with the other scopes. |
|
|
535
|
+
| `auto` | Sourcegraph first, per repository; one the site cannot serve uses its local checkout, restored as usual when missing. Without a token, auto mode asks for authorization like remote mode instead of falling back. |
|
|
536
|
+
|
|
537
|
+
Sourcegraph can serve a repository when the site declares the remote-read
|
|
538
|
+
operations, the registered `git.remote` names the same code host and repository
|
|
539
|
+
as the Sourcegraph registration, one registered path group contains the whole
|
|
540
|
+
`subpath`, and the registered commit is readable. Commands that read remotely
|
|
541
|
+
say so: `context update` and `verify --format json` return `source_access`
|
|
542
|
+
(each repository's `access`, site, repository and commit, or the reason it was
|
|
543
|
+
skipped or read locally), and in `status` each such source has `access: remote`
|
|
544
|
+
instead of checkout advice. `ready` keeps describing the local checkout.
|
|
545
|
+
|
|
546
|
+
**Authorization.** The Sourcegraph MCP server the Agent already uses is the only
|
|
547
|
+
configuration needed. When a command needs a token and has none, it returns a
|
|
548
|
+
`next_action` with `mcp_tool: authorize_cli`, once, at top level
|
|
549
|
+
(`source_authorization`); sources waiting for it are listed with
|
|
550
|
+
`reason_code: sourcegraph-authorization-required` and need no clone. Call that MCP tool once with
|
|
551
|
+
`client: "context"`, then run
|
|
552
|
+
|
|
553
|
+
```bash
|
|
554
|
+
context source sourcegraph-auth --code <code> --host <host> --format json
|
|
555
|
+
```
|
|
556
|
+
|
|
557
|
+
with the returned one-time `code` and `host` (the site's API root). The CLI
|
|
558
|
+
exchanges the code for a temporary read-only token, keeps it in
|
|
559
|
+
`.tmp/context-runtime/sourcegraph/token.json` (mode 600, never committed) and
|
|
560
|
+
reuses it for later commands in this workspace. Authorize again only when a
|
|
561
|
+
command asks for it again: after the token expired unused, was revoked, or
|
|
562
|
+
reached its maximum lifetime. Never print, copy or log the token. If
|
|
563
|
+
`authorize_cli` answers `TEMPORARY_TOKEN_LIMIT`, do not retry; run `context
|
|
564
|
+
source sourcegraph-auth --refused TEMPORARY_TOKEN_LIMIT --format json`, after
|
|
565
|
+
which remote mode skips repository sources and auto mode reads checkouts until
|
|
566
|
+
earlier temporary tokens expire or are revoked in the Sourcegraph user
|
|
567
|
+
settings. On a development machine or in CI, `SOURCEGRAPH_URL` and
|
|
568
|
+
`SOURCEGRAPH_API_TOKEN` take precedence and need no authorization; Sourcegraph
|
|
569
|
+
CLI login configuration is not read.
|
|
570
|
+
|
|
571
|
+
**Versions.** Only the registered commit decides whether a repository can be
|
|
572
|
+
read. When it is not readable yet, `status`, `verify`, revisions and an explicit
|
|
573
|
+
`update --input` report it and change nothing; `context update --pending` asks
|
|
574
|
+
Sourcegraph to prepare its content (when the site allows), waits a bounded time
|
|
575
|
+
and otherwise reports the job and the next step. Rate limits and full quotas
|
|
576
|
+
are reported, never retried in a loop. When only the processed commit is no
|
|
577
|
+
longer readable, the update still runs: history evidence is `unavailable` and
|
|
578
|
+
`uncited_changes` reports the comparison as unknown, as with a shallow checkout.
|
|
579
|
+
A site that cannot list directories still groups uncited changes but marks no
|
|
580
|
+
`new_directory`, and says so in the entry's `note`.
|
|
581
|
+
|
|
582
|
+
**Reading for writing.** For a source the CLI reads from Sourcegraph, size the
|
|
583
|
+
change with the Sourcegraph diff of the processed and registered commits, and
|
|
584
|
+
read or search code through the Sourcegraph MCP tools pinned to the registered
|
|
585
|
+
full commit; do not clone it for the update. A source read locally, a new page
|
|
586
|
+
and code parsing follow the checkout steps above. A read failure in remote mode
|
|
587
|
+
is never a citation change: `verify` reports those citations as not checked.
|
|
588
|
+
|
|
518
589
|
## Versioned external content and archived collections
|
|
519
590
|
|
|
520
591
|
Published content that another team versions, such as a documentation
|
|
@@ -29,6 +29,12 @@ with an `instruction` when an addition or shared change affects it. When the
|
|
|
29
29
|
pages you revise are written by other Agents, give each writer its page's
|
|
30
30
|
`changed_references` entries and their evidence.
|
|
31
31
|
|
|
32
|
+
When the update's `source_access` marks a repository `remote`, its citations,
|
|
33
|
+
evidence and `uncited_changes` were read from Sourcegraph at the registered
|
|
34
|
+
commit and match a local checkout. Inspect its change with the Sourcegraph diff
|
|
35
|
+
and read its code through the Sourcegraph MCP tools at that commit instead of
|
|
36
|
+
cloning it; a new page from it still needs a local checkout.
|
|
37
|
+
|
|
32
38
|
Follow each changed reference's `evidence_ref` into the JSON array in
|
|
33
39
|
`reference_evidence_file` (`reference_evidence_count` entries) for
|
|
34
40
|
digest-verified historical text and the current excerpt. Read only the entries
|