agent-manifesto-kit 1.1.0 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -3
- package/dist/commands/adopt.js +39 -7
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -128,9 +128,15 @@ agentkit adopt sdd --provider codex --cli codex
|
|
|
128
128
|
agentkit adopt brainstorm --provider codex --cli agy
|
|
129
129
|
```
|
|
130
130
|
|
|
131
|
-
The assistant receives a structured prompt
|
|
132
|
-
|
|
133
|
-
|
|
131
|
+
The assistant receives a structured prompt that explicitly frames the adaptation as an
|
|
132
|
+
approved, actionable task (not a proposal), asking it to read your project's local
|
|
133
|
+
instructions and documentation, then adapt the adopted files — including any bundle
|
|
134
|
+
extras such as SDD templates — to your naming, paths, vocabulary, and conventions.
|
|
135
|
+
|
|
136
|
+
Codex runs with a writable sandbox and no approval prompts (`--sandbox workspace-write
|
|
137
|
+
--ask-for-approval never`) so it can make the edits directly instead of stopping to ask.
|
|
138
|
+
Claude Code receives the prompt over stdin rather than as a CLI argument, so large
|
|
139
|
+
prompts never hit OS argument-length limits.
|
|
134
140
|
|
|
135
141
|
Supported AI CLIs:
|
|
136
142
|
|
package/dist/commands/adopt.js
CHANGED
|
@@ -12,9 +12,17 @@ export const SUPPORTED_CLIS = [
|
|
|
12
12
|
export function isSupportedCli(value) {
|
|
13
13
|
return SUPPORTED_CLIS.includes(value);
|
|
14
14
|
}
|
|
15
|
-
const CLI_INVOCATIONS = {
|
|
16
|
-
|
|
17
|
-
|
|
15
|
+
export const CLI_INVOCATIONS = {
|
|
16
|
+
// Piped via stdin (not argv) so large prompts never hit OS ARG_MAX limits.
|
|
17
|
+
claude: { kind: "stdin", bin: "claude", args: ["--dangerously-skip-permissions", "-p"] },
|
|
18
|
+
// workspace-write + never-approval: this handoff already runs in a project
|
|
19
|
+
// the user chose to adapt, so Codex must not fall back to a read-only
|
|
20
|
+
// sandbox or stop to ask for approval mid-run.
|
|
21
|
+
codex: {
|
|
22
|
+
kind: "stdin",
|
|
23
|
+
bin: "codex",
|
|
24
|
+
args: ["exec", "--skip-git-repo-check", "--sandbox", "workspace-write", "--ask-for-approval", "never", "-"],
|
|
25
|
+
},
|
|
18
26
|
agy: { kind: "bash", cmd: 'agy --dangerously-skip-permissions -p "$(cat "$0")"' },
|
|
19
27
|
aider: { kind: "bash", cmd: 'aider --message "$(cat "$0")" --yes-always' },
|
|
20
28
|
opencode: { kind: "bash", cmd: 'opencode run "$(cat "$0")"' },
|
|
@@ -22,10 +30,15 @@ const CLI_INVOCATIONS = {
|
|
|
22
30
|
kilo: { kind: "bash", cmd: 'kilocode --auto "$(cat "$0")"' },
|
|
23
31
|
qwen: { kind: "bash", cmd: 'qwen --prompt "$(cat "$0")"' },
|
|
24
32
|
};
|
|
25
|
-
function buildPrompt(files) {
|
|
26
|
-
return `You have
|
|
33
|
+
export function buildPrompt(files) {
|
|
34
|
+
return `You have been asked, with the user's explicit approval, to adapt the
|
|
35
|
+
following AI capability files that were just adopted into this project:
|
|
27
36
|
${files.join("\n")}
|
|
28
37
|
|
|
38
|
+
This is an approved, actionable task, not a proposal or a discussion point.
|
|
39
|
+
Do not ask for confirmation, do not stop to summarize a plan, and do not
|
|
40
|
+
treat this message as background context — edit the files directly now.
|
|
41
|
+
|
|
29
42
|
Before editing anything:
|
|
30
43
|
1. Read CLAUDE.md (or AGENTS.md if present), README.md, and any project
|
|
31
44
|
specification files under .docs/ or .ai/docs/.
|
|
@@ -36,7 +49,10 @@ Adapt each file to this project:
|
|
|
36
49
|
- Replace generic references with project-specific names, paths, and terms
|
|
37
50
|
- Align tool references and file paths to what this project actually uses
|
|
38
51
|
- Preserve the file's structure, scope, and intent exactly
|
|
39
|
-
- Leave files that need no changes untouched
|
|
52
|
+
- Leave files that need no changes untouched
|
|
53
|
+
|
|
54
|
+
Apply the edits yourself, in this working directory, as your final action —
|
|
55
|
+
do not defer them to the user.`;
|
|
40
56
|
}
|
|
41
57
|
const SPINNER = ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"];
|
|
42
58
|
// On Windows, `bash` in PATH resolves to the WSL relay (C:\Windows\System32\bash.exe),
|
|
@@ -59,7 +75,7 @@ function findBash() {
|
|
|
59
75
|
}
|
|
60
76
|
return "bash";
|
|
61
77
|
}
|
|
62
|
-
async function invokeAi(inv, prompt, cwd, cli) {
|
|
78
|
+
export async function invokeAi(inv, prompt, cwd, cli) {
|
|
63
79
|
console.log(`\nRunning ${cli} to adapt adopted files — this may take a several minutes…`);
|
|
64
80
|
let promptFile;
|
|
65
81
|
let child;
|
|
@@ -142,6 +158,20 @@ function walkMd(dir) {
|
|
|
142
158
|
}
|
|
143
159
|
return out;
|
|
144
160
|
}
|
|
161
|
+
// Dotfiles (.gitkeep, .DS_Store, ...) are housekeeping, not adaptation-worthy content.
|
|
162
|
+
function walkAll(dir) {
|
|
163
|
+
const out = [];
|
|
164
|
+
for (const entry of readdirSync(dir, { withFileTypes: true })) {
|
|
165
|
+
if (entry.name.startsWith("."))
|
|
166
|
+
continue;
|
|
167
|
+
const p = join(dir, entry.name);
|
|
168
|
+
if (entry.isDirectory())
|
|
169
|
+
out.push(...walkAll(p));
|
|
170
|
+
else
|
|
171
|
+
out.push(p);
|
|
172
|
+
}
|
|
173
|
+
return out;
|
|
174
|
+
}
|
|
145
175
|
function surfaceCompanions(recommendsPath) {
|
|
146
176
|
const rows = readFileSync(recommendsPath, "utf8")
|
|
147
177
|
.split("\n")
|
|
@@ -215,6 +245,8 @@ async function adoptBundle(bundle, opts, onFile) {
|
|
|
215
245
|
const dest = join(extrasBase, entry.name);
|
|
216
246
|
mkdirSync(dirname(dest), { recursive: true });
|
|
217
247
|
cpSync(src, dest, { recursive: true });
|
|
248
|
+
for (const f of walkAll(dest))
|
|
249
|
+
onFile?.(f);
|
|
218
250
|
}
|
|
219
251
|
console.log(`Adopted bundle "${bundle.name}" (${opts.provider}) -> ${opts.projectRoot}`);
|
|
220
252
|
for (const { item } of toProcess)
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "agent-manifesto-kit",
|
|
3
|
-
"version": "1.1.
|
|
3
|
+
"version": "1.1.2",
|
|
4
4
|
"description": "CLI to discover and adopt Agent Manifesto Kit capabilities (skills, agents, pipelines) into your project for Claude, Codex, or AI-agnostic targets.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"test": "npm run build && node --test",
|
|
27
27
|
"prepublishOnly": "npm run build && npm test",
|
|
28
28
|
"prepare": "git config core.hooksPath .githooks",
|
|
29
|
-
"version-branch": "node .
|
|
29
|
+
"version-branch": "node .claude/scripts/bump-version.mjs"
|
|
30
30
|
},
|
|
31
31
|
"engines": {
|
|
32
32
|
"node": ">=20"
|