@uniswap/ai-toolkit-nx-claude 0.5.7-next.9 → 0.5.7

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.
Files changed (45) hide show
  1. package/README.md +15 -17
  2. package/dist/cli-generator.cjs +26 -37
  3. package/dist/content/agents/agnostic/claude-docs-initializer.md +516 -0
  4. package/dist/content/agents/agnostic/claude-docs-manager.md +466 -0
  5. package/dist/content/agents/agnostic/plan-reviewer.md +53 -24
  6. package/dist/content/agents/agnostic/planner.md +62 -73
  7. package/dist/content/agents/agnostic/pr-reviewer.md +142 -0
  8. package/dist/content/commands/agnostic/address-pr-issues.md +205 -0
  9. package/dist/content/commands/agnostic/claude-docs.md +410 -0
  10. package/dist/content/commands/agnostic/execute-plan.md +88 -288
  11. package/dist/content/commands/agnostic/explore.md +1 -1
  12. package/dist/content/commands/agnostic/plan.md +65 -201
  13. package/dist/content/commands/agnostic/review-plan.md +11 -12
  14. package/dist/generators/add-agent/generator.cjs +46 -2
  15. package/dist/generators/add-command/generator.cjs +46 -2
  16. package/dist/generators/addons/generator.cjs +80 -233
  17. package/dist/generators/addons/schema.json +0 -5
  18. package/dist/generators/hooks/generator.cjs +116 -2
  19. package/dist/generators/init/CLAUDE.md +277 -48
  20. package/dist/generators/init/generator.cjs +2090 -494
  21. package/dist/generators/init/schema.json +51 -21
  22. package/dist/index.cjs +1966 -0
  23. package/dist/packages/ai-toolkit-nx-claude/src/cli-generator.d.ts +0 -1
  24. package/dist/packages/ai-toolkit-nx-claude/src/cli-generator.d.ts.map +1 -1
  25. package/dist/packages/ai-toolkit-nx-claude/src/generators/addons/addon-registry.d.ts +0 -4
  26. package/dist/packages/ai-toolkit-nx-claude/src/generators/addons/addon-registry.d.ts.map +1 -1
  27. package/dist/packages/ai-toolkit-nx-claude/src/generators/addons/generator.d.ts.map +1 -1
  28. package/dist/packages/ai-toolkit-nx-claude/src/generators/hooks/install-orchestrator.d.ts.map +1 -1
  29. package/dist/packages/ai-toolkit-nx-claude/src/generators/init/generator.d.ts.map +1 -1
  30. package/dist/packages/ai-toolkit-nx-claude/src/index.d.ts +3 -1
  31. package/dist/packages/ai-toolkit-nx-claude/src/index.d.ts.map +1 -1
  32. package/dist/packages/ai-toolkit-nx-claude/src/utils/auto-update-utils.d.ts +30 -0
  33. package/dist/packages/ai-toolkit-nx-claude/src/utils/auto-update-utils.d.ts.map +1 -0
  34. package/dist/packages/ai-toolkit-nx-claude/src/utils/prompt-utils.d.ts.map +1 -1
  35. package/generators.json +0 -5
  36. package/package.json +12 -3
  37. package/dist/generators/init/setup-github-packages.sh +0 -132
  38. package/dist/generators/setup-registry-proxy/README.md +0 -111
  39. package/dist/generators/setup-registry-proxy/files/uniswap-ai-toolkit.__shell__rc.template +0 -178
  40. package/dist/generators/setup-registry-proxy/generator.cjs +0 -227
  41. package/dist/generators/setup-registry-proxy/schema.json +0 -43
  42. package/dist/packages/ai-toolkit-nx-claude/src/generators/addons/github-auth.d.ts +0 -36
  43. package/dist/packages/ai-toolkit-nx-claude/src/generators/addons/github-auth.d.ts.map +0 -1
  44. package/dist/packages/ai-toolkit-nx-claude/src/generators/setup-registry-proxy/generator.d.ts +0 -5
  45. package/dist/packages/ai-toolkit-nx-claude/src/generators/setup-registry-proxy/generator.d.ts.map +0 -1
package/README.md CHANGED
@@ -4,57 +4,55 @@ This package provides Nx generators for setting up and managing Claude Code conf
4
4
 
5
5
  ## Installation
6
6
 
7
- This package is published to GitHub Packages and requires authentication to access. Ensure you have a GitHub personal access token with appropriate scopes configured in your npm settings. More information available in the root README.md file.
8
-
9
- ````bash
7
+ This package is published to a private npmjs package registry and requires authentication to access. See the [root README.md file](../../README.md) for instructions on how to install it via NPM, or run it locally
10
8
 
11
9
  ## Usage
12
10
 
13
11
  ### Run Default Generator
14
12
 
15
13
  ```bash
16
- npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest
17
- ````
14
+ bun nx run @uniswap/ai-toolkit-nx-claude:nx-claude:exec
15
+ ```
18
16
 
19
17
  ### Run Specific Generators
20
18
 
21
- Each generator can be run directly using colon syntax:
19
+ Each generator can be run directly desired generator's subcommand:
22
20
 
23
21
  ```bash
24
22
  # One-shot installer for Claude Code configs
25
- npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest init
23
+ bun nx run @uniswap/ai-toolkit-nx-claude:nx-claude:exec init
26
24
 
27
25
  # Install notification hooks
28
- npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest hooks
29
-
30
- # Setup shell proxy for GitHub registry routing
31
- npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest setup-registry-proxy
26
+ bun nx run @uniswap/ai-toolkit-nx-claude:nx-claude:exec hooks
32
27
 
33
28
  # Install and configure Claude Code addons
34
- npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest addons
29
+ bun nx run @uniswap/ai-toolkit-nx-claude:nx-claude:exec addons
35
30
 
36
31
  # Add a new command to packages
37
- npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest add-command
32
+ bun nx run @uniswap/ai-toolkit-nx-claude:nx-claude:exec add-command
38
33
 
39
34
  # Add a new agent to packages
40
- npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest add-agent
35
+ bun nx run @uniswap/ai-toolkit-nx-claude:nx-claude:exec add-agent
41
36
  ```
42
37
 
43
38
  ### List Available Generators
44
39
 
45
40
  ```bash
46
- npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest --list
41
+ bun nx run @uniswap/ai-toolkit-nx-claude:nx-claude:exec --list
47
42
  ```
48
43
 
49
44
  ## Available Generators
50
45
 
51
46
  - **init** - One-shot installer for Claude Code configs
52
47
  - **hooks** - Install Claude Code notification hooks
53
- - **setup-registry-proxy** - Setup shell proxy for routing @uniswap/ai-toolkit\* packages to GitHub registry
54
48
  - **addons** - Install and configure Claude Code addons including MCP servers
55
49
  - **add-command** - Add a new Claude Code command to existing or new packages
56
50
  - **add-agent** - Add a new Claude Code agent to existing or new packages
57
51
 
58
52
  ## Building
59
53
 
60
- Run `nx build ai-toolkit-nx-claude` to build the library.
54
+ Run `bun nx build ai-toolkit-nx-claude` to build the library.
55
+
56
+ ## Testing
57
+
58
+ Run `bunx nx test ai-toolkit-nx-claude` to test this library
@@ -30,7 +30,7 @@ var fs = __toESM(require("fs"));
30
30
  async function handleNxExecution(generatorName, args) {
31
31
  if (args.includes("--help") || args.includes("-h")) {
32
32
  console.log(
33
- `Usage: npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest ${generatorName}`
33
+ `Usage: npx @uniswap/ai-toolkit-nx-claude@latest ${generatorName}`
34
34
  );
35
35
  console.log(
36
36
  `
@@ -68,18 +68,10 @@ function handleExecutionError(error, generatorName) {
68
68
  );
69
69
  console.error("You do not have permission to access this package.");
70
70
  console.error(
71
- "\nThis package is restricted to members of the Uniswap GitHub organization."
71
+ "\nThis package requires a read-only npm token to access the private npmjs registry."
72
72
  );
73
73
  console.error("\nTo gain access:");
74
- console.error(
75
- "1. Verify you are a member of the Uniswap organization on GitHub"
76
- );
77
- console.error(
78
- '2. Check that your npm token has the required "read:packages" scope'
79
- );
80
- console.error(
81
- "\nFor more information, see: https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-npm-registry#authenticating-to-github-packages"
82
- );
74
+ console.error("1. See the top-level README for setup instructions.");
83
75
  console.error(
84
76
  "\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"
85
77
  );
@@ -94,11 +86,7 @@ function handleExecutionError(error, generatorName) {
94
86
  console.error("\nThis may be because:");
95
87
  console.error("1. The package has not been published yet");
96
88
  console.error(
97
- "2. You are not authenticated properly (check your GitHub PAT)"
98
- );
99
- console.error("\nTry running:");
100
- console.error(
101
- ' echo "//npm.pkg.github.com/:_authToken=YOUR_GITHUB_TOKEN" >> ~/.npmrc'
89
+ "2. You are not authenticated properly (check the top-level README for NPM authenticationsetup instructions)"
102
90
  );
103
91
  console.error(
104
92
  "\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501"
@@ -140,7 +128,6 @@ async function runGeneratorDirectly(generatorName, args) {
140
128
  const generatorFunctionMap = {
141
129
  init: "initGenerator",
142
130
  hooks: "hooksGenerator",
143
- "setup-registry-proxy": "setupRegistryProxyGenerator",
144
131
  addons: "addonsGenerator",
145
132
  "add-command": "addCommandGenerator",
146
133
  "add-agent": "addAgentGenerator"
@@ -340,10 +327,8 @@ function isInAiToolkitRepo() {
340
327
  return isInAiToolkit;
341
328
  }
342
329
  var GENERATORS = {
343
- init: "One-shot installer for Claude Code configs",
344
- hooks: "Install Claude Code notification hooks",
345
- addons: "Install and configure Claude Code addons including MCP servers",
346
- "setup-registry-proxy": "Setup shell proxy for routing @uniswap/ai-toolkit* packages to GitHub registry"
330
+ "default-install": "Recommended setup with pre-selected components",
331
+ "custom-install": "Choose exactly what to install"
347
332
  };
348
333
  var ALL_GENERATORS = isInAiToolkitRepo() ? {
349
334
  ...GENERATORS,
@@ -394,22 +379,16 @@ async function main() {
394
379
  console.log(` ${name.padEnd(25)} ${description}`);
395
380
  });
396
381
  console.log("\nUsage:");
397
- console.log(
398
- " npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest [generator]"
399
- );
382
+ console.log(" npx @uniswap/ai-toolkit-nx-claude@latest [generator]");
400
383
  console.log("\nExamples:");
401
- console.log(
402
- " npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest init"
403
- );
404
- console.log(
405
- " npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest hooks"
406
- );
384
+ console.log(" npx @uniswap/ai-toolkit-nx-claude@latest default-install");
385
+ console.log(" npx @uniswap/ai-toolkit-nx-claude@latest custom-install");
407
386
  process.exit(0);
408
387
  }
409
388
  if (processedArgs.includes("--help") || processedArgs.includes("-h")) {
410
389
  if (generatorName) {
411
390
  console.log(
412
- `Usage: npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest ${generatorName}`
391
+ `Usage: npx @uniswap/ai-toolkit-nx-claude@latest ${generatorName}`
413
392
  );
414
393
  console.log(
415
394
  `
@@ -417,15 +396,13 @@ This command runs the nx-claude ${generatorName} generator.`
417
396
  );
418
397
  } else {
419
398
  console.log(
420
- "Usage: npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest [generator]"
399
+ "Usage: npx @uniswap/ai-toolkit-nx-claude@latest [generator]"
421
400
  );
422
401
  console.log("\nRun without arguments for interactive mode.");
423
402
  }
424
403
  console.log("\nTo see all available generators, run with --list");
425
404
  console.log("\nTo run a specific generator:");
426
- console.log(
427
- " npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest [generator]"
428
- );
405
+ console.log(" npx @uniswap/ai-toolkit-nx-claude@latest [generator]");
429
406
  console.log("\nOptions are handled interactively during execution.");
430
407
  console.log("\nFor more information, see the package documentation.");
431
408
  process.exit(0);
@@ -437,11 +414,23 @@ This command runs the nx-claude ${generatorName} generator.`
437
414
  if (!generatorName) {
438
415
  console.error("\n\u274C No generator specified.");
439
416
  console.error(
440
- "\nUsage: npx --@uniswap:registry=https://npm.pkg.github.com @uniswap/ai-toolkit-nx-claude@latest [generator]"
417
+ "\nUsage: npx @uniswap/ai-toolkit-nx-claude@latest [generator]"
441
418
  );
442
419
  console.error("\nRun with --list to see available generators.");
443
420
  process.exit(1);
444
421
  }
445
- await handleNxExecution(generatorName, processedArgs);
422
+ if (generatorName === "default-install") {
423
+ await handleNxExecution("init", [
424
+ ...processedArgs,
425
+ "--install-mode=default"
426
+ ]);
427
+ } else if (generatorName === "custom-install") {
428
+ await handleNxExecution("init", [
429
+ ...processedArgs,
430
+ "--install-mode=custom"
431
+ ]);
432
+ } else {
433
+ await handleNxExecution(generatorName, processedArgs);
434
+ }
446
435
  }
447
436
  main().catch(console.error);