@c4a/context-cli 0.6.8 → 0.6.10
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 +156 -220
- package/README.zh-CN.md +120 -160
- package/cli.js +265 -58
- package/docs/quickstart.md +57 -70
- package/docs/quickstart.zh-CN.md +79 -0
- package/package.json +4 -4
- package/plugins/.agents/plugins/marketplace.json +1 -1
- package/plugins/.claude-plugin/marketplace.json +2 -2
- package/plugins/.cursor-plugin/marketplace.json +2 -2
- package/plugins/README.md +79 -66
- package/plugins/README_CN.md +62 -57
- package/plugins/VERSION +1 -1
- package/plugins/claude/.claude-plugin/plugin.json +3 -3
- package/plugins/claude/commands/context.md +121 -0
- package/plugins/codex/.codex-plugin/plugin.json +4 -4
- package/plugins/codex/skills/context/SKILL.md +133 -0
- package/plugins/cursor/.cursor-plugin/plugin.json +3 -3
- package/plugins/cursor/README.md +2 -2
- package/plugins/cursor/commands/c4a-context.md +125 -0
- package/plugins/skills/c4a-context/SKILL.md +133 -0
- package/providers/context/graphs/workspace.yaml +40 -1
- package/providers/context/manifest.json +27 -9
- package/providers/context/provider.yaml +2 -2
- package/providers/context/resources/dialogue/workflow-mode-after-capture.md +22 -0
- package/providers/context/resources/dialogue/workflow-mode-after-creation.md +25 -0
- package/providers/context/resources/manuals/guides/package-outputs.md +1 -1
- package/providers/context/resources/manuals/reference/package-templates.md +1 -1
- package/plugins/claude/commands/continue.md +0 -109
- package/plugins/claude/commands/init.md +0 -36
- package/plugins/codex/skills/continue/SKILL.md +0 -121
- package/plugins/codex/skills/init/SKILL.md +0 -48
- package/plugins/cursor/commands/context-continue.md +0 -113
- package/plugins/cursor/commands/context-init.md +0 -40
- package/plugins/skills/context-continue/SKILL.md +0 -121
- package/plugins/skills/context-init/SKILL.md +0 -48
|
@@ -1,121 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: context-continue
|
|
3
|
-
description: >
|
|
4
|
-
Inspect the Context workspace, decide the next useful action, and proceed. Use the local `context` CLI for workspace writes.
|
|
5
|
-
tools:
|
|
6
|
-
- Bash
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
# Continue
|
|
10
|
-
|
|
11
|
-
Public Context entry for agents that expose skills instead of slash commands.
|
|
12
|
-
|
|
13
|
-
- Public entry: `context-continue`
|
|
14
|
-
- Host command names are installation-specific; use the command or skill surfaced by the current host instead of deriving a filesystem path from an example name.
|
|
15
|
-
- CLI primitive prefix: `context ...`
|
|
16
|
-
|
|
17
|
-
---
|
|
18
|
-
|
|
19
|
-
## Workflow
|
|
20
|
-
|
|
21
|
-
Use this as the conversational entry for an existing Context workspace. There
|
|
22
|
-
is no `context continue` CLI primitive. Without explicit fully managed
|
|
23
|
-
authority, start with:
|
|
24
|
-
|
|
25
|
-
```bash
|
|
26
|
-
context status --format json
|
|
27
|
-
```
|
|
28
|
-
|
|
29
|
-
If the user explicitly asks to enable debugging, first run
|
|
30
|
-
`context debug enable`. It sets `package.json` `context.debug=true` and records
|
|
31
|
-
subsequent CLI and Agent Graph events only below `.tmp/context-runtime/debug/`.
|
|
32
|
-
Do not enable it proactively; tracing is not workflow authority or evidence.
|
|
33
|
-
|
|
34
|
-
When the user explicitly requests fully managed operation in this conversation,
|
|
35
|
-
start with the managed loop instead of a manual status/action cycle:
|
|
36
|
-
|
|
37
|
-
```bash
|
|
38
|
-
context run --managed --until blocked-or-complete --format json
|
|
39
|
-
```
|
|
40
|
-
|
|
41
|
-
That explicit managed authority is also the user's explicit authorization for a
|
|
42
|
-
current `route.logs.delivery-pending` action, but only through the installed
|
|
43
|
-
package's fixed runtime-event sink. This route can appear only after a build
|
|
44
|
-
completed and its accumulated outbox batch failed to send. Initialization,
|
|
45
|
-
workspace-activity, and close delivery failures stay silent and must never
|
|
46
|
-
request host escalation by themselves. Do not ask for endpoint-specific
|
|
47
|
-
consent again or stop merely because delivery uses an external telemetry
|
|
48
|
-
endpoint.
|
|
49
|
-
When this route appears, read its required delivery procedure, run
|
|
50
|
-
`context logs plan --format json`, and use the returned outbox path, event
|
|
51
|
-
summary, HTTP destination, method, and data policy in the Agent-host network
|
|
52
|
-
approval request, including both proxy and upstream destinations when present.
|
|
53
|
-
Changes to the batch's event count, event-kind mix, or property-key mix are
|
|
54
|
-
audit details, not a new consent boundary, while the returned destination,
|
|
55
|
-
input schema, and data policy remain the same. The batch may include queued
|
|
56
|
-
initialization, activity, or close events in addition to the build event; do
|
|
57
|
-
not ask the user again because that allowlisted payload composition changed.
|
|
58
|
-
Immediately execute only the returned `flush_command` as a top-level Agent-host
|
|
59
|
-
action and request host network escalation in that tool invocation; never add
|
|
60
|
-
an arbitrary payload or destination option. A host approval prompt is an
|
|
61
|
-
execution boundary, not a new conversational user decision. Stop only when the
|
|
62
|
-
host denies that request, the host-network execution still fails, or the plan
|
|
63
|
-
has no resolved HTTP destination.
|
|
64
|
-
|
|
65
|
-
Never persist or reuse that authority in another conversation. While the
|
|
66
|
-
request remains active, use `--managed` for every resumed status evaluation;
|
|
67
|
-
stop using it when the conversation ends or the user revokes it.
|
|
68
|
-
|
|
69
|
-
If the user is starting a new workspace or a new batch from a raw repository
|
|
70
|
-
root, do not run `context status` first. Use the public Context init entry or
|
|
71
|
-
`context init` to create the workspace, complete the init setup command, then
|
|
72
|
-
return here from the initialized workspace.
|
|
73
|
-
|
|
74
|
-
The managed loop is the default entry for an explicitly managed conversation,
|
|
75
|
-
not an optional optimization. Pass an additional `--authority` only when the user explicitly granted that
|
|
76
|
-
non-managed authority in this conversation. This loop executes only one
|
|
77
|
-
revision-bound command at a time and re-evaluates after every receipt. It stops
|
|
78
|
-
before read-only interpretation, project configuration, unresolved authority,
|
|
79
|
-
diagnostics, or a non-unique command plan. On stop, resume from the returned
|
|
80
|
-
`workflow.current`; do not derive a command from earlier steps.
|
|
81
|
-
|
|
82
|
-
Language policy: explain, ask, confirm, and summarize in the user's current
|
|
83
|
-
conversation language. Keep CLI commands, flags, paths, ids, status enum values,
|
|
84
|
-
JSONL payload keys, `source_ref` values, and copied CLI output tokens unchanged.
|
|
85
|
-
|
|
86
|
-
Treat `workflow.current` as the current-step authority:
|
|
87
|
-
|
|
88
|
-
1. Read every `resources.required` item whose `read_state` is
|
|
89
|
-
`read-required`. Read a `path` directly; for a resource with `command`,
|
|
90
|
-
execute that command and read the returned file. Keep read receipts only in
|
|
91
|
-
the current conversation and pass the merged receipt set back with
|
|
92
|
-
`context status --resource-receipts @<file>`; an unchanged static digest or
|
|
93
|
-
matching dynamic Route revision then returns `read_state: current`.
|
|
94
|
-
Materializing a resource is not a read: use the returned
|
|
95
|
-
`after_read_receipts` only after reading the complete returned file. A
|
|
96
|
-
`context.source-body/*` resource is the complete captured Markdown body;
|
|
97
|
-
source indexes and heading metadata never replace it. The exact
|
|
98
|
-
`resources.after_read.command` returns the re-evaluated `workflow.current`;
|
|
99
|
-
continue from that response without an additional status call.
|
|
100
|
-
2. At a Gate, keep conditional context phase-local. An `inspection_action`
|
|
101
|
-
Skill or Schema is read only when performing that pre-decision inspection;
|
|
102
|
-
a `resolution_action` Skill or Schema is read only after the user confirms
|
|
103
|
-
the Gate. Neither replaces ordinary `resources.required`.
|
|
104
|
-
3. Execute only `commands` returned by the Route, preserving revision and
|
|
105
|
-
authority flags exactly. A command marked `after-human-confirmation` must
|
|
106
|
-
wait for the current Gate decision. Run a command whose
|
|
107
|
-
`execution.target` is `agent-host` as a top-level host action with the
|
|
108
|
-
host's external and credential access, not inside a restricted child
|
|
109
|
-
sandbox. Request host approval when required; never weaken credential
|
|
110
|
-
storage as a workaround.
|
|
111
|
-
4. If `configuration` is present, edit only the named project file using the
|
|
112
|
-
selected resources as its contract.
|
|
113
|
-
5. After every action or configuration change, run status again. The managed
|
|
114
|
-
`--until` loop performs this re-evaluation internally. A phase-local
|
|
115
|
-
`next_action` can continue that operation but never replaces the workspace
|
|
116
|
-
Route.
|
|
117
|
-
|
|
118
|
-
Do not infer repo sources, extraction scope, review decisions, or package output
|
|
119
|
-
choices from surrounding files. Do not call source-repo operations such as
|
|
120
|
-
clone, checkout, reset, fetch, install, build, or test without explicit user
|
|
121
|
-
approval.
|
|
@@ -1,48 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: context-init
|
|
3
|
-
description: >
|
|
4
|
-
Initialize a Context knowledge workspace. Use the local `context` CLI for workspace writes.
|
|
5
|
-
tools:
|
|
6
|
-
- Bash
|
|
7
|
-
---
|
|
8
|
-
|
|
9
|
-
# Init
|
|
10
|
-
|
|
11
|
-
Public Context entry for agents that expose skills instead of slash commands.
|
|
12
|
-
|
|
13
|
-
- Public entry: `context-init`
|
|
14
|
-
- Host command names are installation-specific; use the command or skill surfaced by the current host instead of deriving a filesystem path from an example name.
|
|
15
|
-
- CLI primitive prefix: `context ...`
|
|
16
|
-
|
|
17
|
-
---
|
|
18
|
-
|
|
19
|
-
## Workflow
|
|
20
|
-
|
|
21
|
-
Initialize a Context workspace with the global CLI, complete the returned setup
|
|
22
|
-
step, then hand control to the current workflow route.
|
|
23
|
-
|
|
24
|
-
Use the user's language for conversation. Keep command and payload tokens
|
|
25
|
-
unchanged.
|
|
26
|
-
|
|
27
|
-
Run `context init [project-dir] [--name <name>] --language <language>`. Use the
|
|
28
|
-
user's explicit language choice when present; otherwise pass `zh-CN` for a
|
|
29
|
-
Chinese conversation and `en` for an English conversation. This explicit CLI
|
|
30
|
-
value controls generated workspace instructions and starter templates. Never
|
|
31
|
-
substitute `.` when `project-dir` was omitted; the default is `context/`. Use
|
|
32
|
-
`--dev` only for an explicitly requested local-link test.
|
|
33
|
-
Add `--debug` only when the user explicitly asks to trace this workspace. Debug
|
|
34
|
-
mode is otherwise off by default.
|
|
35
|
-
|
|
36
|
-
If init reports `init-target-nonempty`, explain that existing files would share
|
|
37
|
-
the workspace root. Run the returned `--allow-nonempty` command only after
|
|
38
|
-
explicit confirmation.
|
|
39
|
-
|
|
40
|
-
Execute the returned setup command, enter the project root, and read its
|
|
41
|
-
generated `AGENTS.md`. Then run `context status --format json`, adding
|
|
42
|
-
`--managed` only for fully managed operation explicitly authorized in this
|
|
43
|
-
conversation. Treat `workflow.current` as authoritative: read its required
|
|
44
|
-
resources, execute only exact commands, honor unresolved human gates, and
|
|
45
|
-
reevaluate status after each action.
|
|
46
|
-
|
|
47
|
-
Do not add extra project-local agent setup or infer sources from the surrounding
|
|
48
|
-
monorepo.
|