@ai-hero/sandcastle 0.4.4 → 0.4.6

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 (89) hide show
  1. package/README.md +48 -19
  2. package/dist/AgentProvider.d.ts +8 -2
  3. package/dist/AgentProvider.d.ts.map +1 -1
  4. package/dist/AgentProvider.js +34 -14
  5. package/dist/AgentProvider.js.map +1 -1
  6. package/dist/{CopyToSandbox.d.ts → CopyToWorkspace.d.ts} +2 -2
  7. package/dist/CopyToWorkspace.d.ts.map +1 -0
  8. package/dist/{CopyToSandbox.js → CopyToWorkspace.js} +2 -2
  9. package/dist/CopyToWorkspace.js.map +1 -0
  10. package/dist/ErrorHandler.d.ts.map +1 -1
  11. package/dist/ErrorHandler.js +3 -0
  12. package/dist/ErrorHandler.js.map +1 -1
  13. package/dist/InitService.d.ts +24 -0
  14. package/dist/InitService.d.ts.map +1 -1
  15. package/dist/InitService.js +117 -11
  16. package/dist/InitService.js.map +1 -1
  17. package/dist/Orchestrator.d.ts.map +1 -1
  18. package/dist/Orchestrator.js +4 -1
  19. package/dist/Orchestrator.js.map +1 -1
  20. package/dist/PodmanLifecycle.d.ts +17 -0
  21. package/dist/PodmanLifecycle.d.ts.map +1 -0
  22. package/dist/PodmanLifecycle.js +45 -0
  23. package/dist/PodmanLifecycle.js.map +1 -0
  24. package/dist/PromptArgumentSubstitution.d.ts +5 -0
  25. package/dist/PromptArgumentSubstitution.d.ts.map +1 -1
  26. package/dist/PromptArgumentSubstitution.js +22 -0
  27. package/dist/PromptArgumentSubstitution.js.map +1 -1
  28. package/dist/PromptPreprocessor.d.ts.map +1 -1
  29. package/dist/PromptPreprocessor.js +6 -0
  30. package/dist/PromptPreprocessor.js.map +1 -1
  31. package/dist/SandboxFactory.d.ts +3 -3
  32. package/dist/SandboxFactory.d.ts.map +1 -1
  33. package/dist/SandboxFactory.js +3 -3
  34. package/dist/SandboxFactory.js.map +1 -1
  35. package/dist/SandboxLifecycle.d.ts.map +1 -1
  36. package/dist/SandboxLifecycle.js +7 -7
  37. package/dist/SandboxLifecycle.js.map +1 -1
  38. package/dist/SandboxProvider.d.ts +73 -1
  39. package/dist/SandboxProvider.d.ts.map +1 -1
  40. package/dist/SandboxProvider.js.map +1 -1
  41. package/dist/cli.d.ts +10 -6
  42. package/dist/cli.d.ts.map +1 -1
  43. package/dist/cli.js +113 -113
  44. package/dist/cli.js.map +1 -1
  45. package/dist/createSandbox.d.ts +23 -1
  46. package/dist/createSandbox.d.ts.map +1 -1
  47. package/dist/createSandbox.js +63 -6
  48. package/dist/createSandbox.js.map +1 -1
  49. package/dist/errors.d.ts +9 -1
  50. package/dist/errors.d.ts.map +1 -1
  51. package/dist/errors.js +3 -0
  52. package/dist/errors.js.map +1 -1
  53. package/dist/index.d.ts +5 -3
  54. package/dist/index.d.ts.map +1 -1
  55. package/dist/index.js +1 -0
  56. package/dist/index.js.map +1 -1
  57. package/dist/interactive.d.ts +52 -0
  58. package/dist/interactive.d.ts.map +1 -0
  59. package/dist/interactive.js +231 -0
  60. package/dist/interactive.js.map +1 -0
  61. package/dist/run.d.ts +1 -1
  62. package/dist/run.d.ts.map +1 -1
  63. package/dist/run.js +5 -5
  64. package/dist/run.js.map +1 -1
  65. package/dist/sandboxes/docker.d.ts.map +1 -1
  66. package/dist/sandboxes/docker.js +26 -1
  67. package/dist/sandboxes/docker.js.map +1 -1
  68. package/dist/sandboxes/no-sandbox.d.ts +25 -0
  69. package/dist/sandboxes/no-sandbox.d.ts.map +1 -0
  70. package/dist/sandboxes/no-sandbox.js +91 -0
  71. package/dist/sandboxes/no-sandbox.js.map +1 -0
  72. package/dist/sandboxes/podman.d.ts +10 -2
  73. package/dist/sandboxes/podman.d.ts.map +1 -1
  74. package/dist/sandboxes/podman.js +79 -11
  75. package/dist/sandboxes/podman.js.map +1 -1
  76. package/dist/templates/blank/prompt.md +1 -1
  77. package/dist/templates/parallel-planner/implement-prompt.md +2 -2
  78. package/dist/templates/parallel-planner/main.mts +12 -12
  79. package/dist/templates/parallel-planner/plan-prompt.md +3 -3
  80. package/dist/templates/parallel-planner-with-review/implement-prompt.md +2 -2
  81. package/dist/templates/parallel-planner-with-review/main.mts +11 -11
  82. package/dist/templates/parallel-planner-with-review/plan-prompt.md +3 -3
  83. package/dist/templates/sequential-reviewer/implement-prompt.md +2 -2
  84. package/dist/templates/sequential-reviewer/main.mts +3 -3
  85. package/dist/templates/simple-loop/main.mts +2 -2
  86. package/dist/templates/simple-loop/prompt.md +2 -2
  87. package/package.json +8 -2
  88. package/dist/CopyToSandbox.d.ts.map +0 -1
  89. package/dist/CopyToSandbox.js.map +0 -1
@@ -36,7 +36,7 @@ const hooks = {
36
36
  // Copy node_modules from the host into the worktree before each sandbox
37
37
  // starts. Avoids a full npm install from scratch; the hook above handles
38
38
  // platform-specific binaries and any packages added since the last copy.
39
- const copyToSandbox = ["node_modules"];
39
+ const copyToWorkspace = ["node_modules"];
40
40
 
41
41
  // ---------------------------------------------------------------------------
42
42
  // Main loop
@@ -57,7 +57,7 @@ for (let iteration = 1; iteration <= MAX_ITERATIONS; iteration++) {
57
57
  // -------------------------------------------------------------------------
58
58
  const implement = await sandcastle.run({
59
59
  hooks,
60
- copyToSandbox,
60
+ copyToWorkspace,
61
61
  sandbox: docker(),
62
62
  branchStrategy: { type: "merge-to-head" },
63
63
  name: "implementer",
@@ -86,7 +86,7 @@ for (let iteration = 1; iteration <= MAX_ITERATIONS; iteration++) {
86
86
  // -------------------------------------------------------------------------
87
87
  await sandcastle.run({
88
88
  hooks,
89
- copyToSandbox,
89
+ copyToWorkspace,
90
90
  sandbox: docker(),
91
91
  branchStrategy: { type: "branch", branch },
92
92
  name: "reviewer",
@@ -28,7 +28,7 @@ await run({
28
28
 
29
29
  // Branch strategy — merge-to-head creates a temporary branch for the agent
30
30
  // to work on, then merges the result back to HEAD when the run completes.
31
- // This is required when using copyToSandbox, since head mode bind-mounts
31
+ // This is required when using copyToWorkspace, since head mode bind-mounts
32
32
  // the host directory directly (no worktree to copy into).
33
33
  branchStrategy: { type: "merge-to-head" },
34
34
 
@@ -36,7 +36,7 @@ await run({
36
36
  // starts. This avoids a full npm install from scratch on every iteration.
37
37
  // The onSandboxReady hook still runs npm install as a safety net to handle
38
38
  // platform-specific binaries and any packages added since the last copy.
39
- copyToSandbox: ["node_modules"],
39
+ copyToWorkspace: ["node_modules"],
40
40
 
41
41
  // Lifecycle hooks — commands that run inside the sandbox at specific points.
42
42
  hooks: {
@@ -2,7 +2,7 @@
2
2
 
3
3
  ## Open issues
4
4
 
5
- !`gh issue list --label Sandcastle --json number,title,body --limit 20`
5
+ !`{{LIST_TASKS_COMMAND}}`
6
6
 
7
7
  ## Recent RALPH commits (last 10)
8
8
 
@@ -35,7 +35,7 @@ Pick the highest-priority open issue that is not blocked by another open issue.
35
35
  - List key decisions made
36
36
  - List files changed
37
37
  - Note any blockers for the next iteration
38
- 6. **Close** — close the issue with `gh issue close <number> --comment "..."` explaining what was done.
38
+ 6. **Close** — close the issue with `{{CLOSE_TASK_COMMAND}}` explaining what was done.
39
39
 
40
40
  ## Rules
41
41
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ai-hero/sandcastle",
3
- "version": "0.4.4",
3
+ "version": "0.4.6",
4
4
  "description": "CLI for orchestrating AI agents in isolated sandbox environments",
5
5
  "type": "module",
6
6
  "main": "./dist/index.js",
@@ -25,6 +25,10 @@
25
25
  "./sandboxes/daytona": {
26
26
  "import": "./dist/sandboxes/daytona.js",
27
27
  "types": "./dist/sandboxes/daytona.d.ts"
28
+ },
29
+ "./sandboxes/no-sandbox": {
30
+ "import": "./dist/sandboxes/no-sandbox.js",
31
+ "types": "./dist/sandboxes/no-sandbox.d.ts"
28
32
  }
29
33
  },
30
34
  "bin": {
@@ -41,7 +45,9 @@
41
45
  "prepare": "husky",
42
46
  "release": "changeset publish",
43
47
  "sandcastle": "npm run build && tsx .sandcastle/run.ts",
44
- "test-vercel": "npm run build && tsx --env-file=.sandcastle/.env .sandcastle/test-vercel.ts"
48
+ "test-podman": "npm run build && tsx --env-file=.sandcastle/.env .sandcastle/test-podman.ts",
49
+ "test-vercel": "npm run build && tsx --env-file=.sandcastle/.env .sandcastle/test-vercel.ts",
50
+ "test-interactive": "npm run build && tsx --env-file=.sandcastle/.env .sandcastle/test-interactive.ts"
45
51
  },
46
52
  "keywords": [
47
53
  "cli",
@@ -1 +0,0 @@
1
- {"version":3,"file":"CopyToSandbox.d.ts","sourceRoot":"","sources":["../src/CopyToSandbox.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEhC;;;;GAIG;AACH,eAAO,MAAM,aAAa,mGAyBtB,CAAC"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"CopyToSandbox.js","sourceRoot":"","sources":["../src/CopyToSandbox.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,oBAAoB,CAAC;AAC9C,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AACjC,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEhC;;;;GAIG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,CAC3B,KAAe,EACf,WAAmB,EACnB,YAAoB,EACQ,EAAE,CAC9B,MAAM,CAAC,GAAG,CAAC,QAAQ,CAAC;IAClB,KAAK,MAAM,YAAY,IAAI,KAAK,EAAE,CAAC;QACjC,MAAM,GAAG,GAAG,IAAI,CAAC,WAAW,EAAE,YAAY,CAAC,CAAC;QAC5C,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,EAAE,CAAC;YACrB,SAAS;QACX,CAAC;QACD,MAAM,IAAI,GAAG,IAAI,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC;QAC9C,KAAK,CAAC,CAAC,MAAM,CAAC,KAAK,CAAc,CAAC,MAAM,EAAE,EAAE;YAC1C,QAAQ,CAAC,IAAI,EAAE,CAAC,IAAI,EAAE,gBAAgB,EAAE,GAAG,EAAE,IAAI,CAAC,EAAE,CAAC,KAAK,EAAE,EAAE;gBAC5D,IAAI,KAAK,EAAE,CAAC;oBACV,0DAA0D;oBAC1D,QAAQ,CAAC,IAAI,EAAE,CAAC,IAAI,EAAE,GAAG,EAAE,IAAI,CAAC,EAAE,GAAG,EAAE;wBACrC,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC;oBACpC,CAAC,CAAC,CAAC;gBACL,CAAC;qBAAM,CAAC;oBACN,MAAM,CAAC,MAAM,CAAC,OAAO,CAAC,SAAS,CAAC,CAAC,CAAC;gBACpC,CAAC;YACH,CAAC,CAAC,CAAC;QACL,CAAC,CAAC,CAAC;IACL,CAAC;AACH,CAAC,CAAC,CAAC"}