@nodetool-ai/cli 0.7.0-rc.23 → 0.8.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 +82 -0
- package/dist/.nodetool-build-stamp +1 -0
- package/dist/ExecutionTree.d.ts +2 -1
- package/dist/ExecutionTree.d.ts.map +1 -1
- package/dist/ExecutionTree.js +1 -1
- package/dist/ExecutionTree.js.map +1 -1
- package/dist/affected/affected.d.ts +45 -0
- package/dist/affected/affected.d.ts.map +1 -0
- package/dist/affected/affected.js +160 -0
- package/dist/affected/affected.js.map +1 -0
- package/dist/agent-toolbelt.d.ts +15 -0
- package/dist/agent-toolbelt.d.ts.map +1 -0
- package/dist/agent-toolbelt.js +28 -0
- package/dist/agent-toolbelt.js.map +1 -0
- package/dist/api-client.d.ts +12 -0
- package/dist/api-client.d.ts.map +1 -0
- package/dist/api-client.js +21 -0
- package/dist/api-client.js.map +1 -0
- package/dist/app-build/bundle.d.ts +15 -0
- package/dist/app-build/bundle.d.ts.map +1 -0
- package/dist/app-build/bundle.js +45 -0
- package/dist/app-build/bundle.js.map +1 -0
- package/dist/app-build/watch.d.ts +13 -0
- package/dist/app-build/watch.d.ts.map +1 -0
- package/dist/app-build/watch.js +25 -0
- package/dist/app-build/watch.js.map +1 -0
- package/dist/app-debug/app-target.d.ts +14 -0
- package/dist/app-debug/app-target.d.ts.map +1 -0
- package/dist/app-debug/app-target.js +120 -0
- package/dist/app-debug/app-target.js.map +1 -0
- package/dist/app-debug/harness.d.ts +29 -0
- package/dist/app-debug/harness.d.ts.map +1 -0
- package/dist/app-debug/harness.js +116 -0
- package/dist/app-debug/harness.js.map +1 -0
- package/dist/app-debug/index.d.ts +12 -0
- package/dist/app-debug/index.d.ts.map +1 -0
- package/dist/app-debug/index.js +9 -0
- package/dist/app-debug/index.js.map +1 -0
- package/dist/app.d.ts +38 -48
- package/dist/app.d.ts.map +1 -1
- package/dist/app.js +980 -677
- package/dist/app.js.map +1 -1
- package/dist/bash-tool.d.ts +13 -0
- package/dist/bash-tool.d.ts.map +1 -0
- package/dist/bash-tool.js +85 -0
- package/dist/bash-tool.js.map +1 -0
- package/dist/chat-codeact.d.ts +93 -0
- package/dist/chat-codeact.d.ts.map +1 -0
- package/dist/chat-codeact.js +179 -0
- package/dist/chat-codeact.js.map +1 -0
- package/dist/chat-context.d.ts +18 -0
- package/dist/chat-context.d.ts.map +1 -0
- package/dist/chat-context.js +32 -0
- package/dist/chat-context.js.map +1 -0
- package/dist/chat-media.d.ts +3 -0
- package/dist/chat-media.d.ts.map +1 -0
- package/dist/chat-media.js +46 -0
- package/dist/chat-media.js.map +1 -0
- package/dist/chat-prompts.d.ts +20 -0
- package/dist/chat-prompts.d.ts.map +1 -0
- package/dist/chat-prompts.js +42 -0
- package/dist/chat-prompts.js.map +1 -0
- package/dist/chat-sessions.d.ts +25 -0
- package/dist/chat-sessions.d.ts.map +1 -0
- package/dist/chat-sessions.js +153 -0
- package/dist/chat-sessions.js.map +1 -0
- package/dist/command-errors.d.ts +10 -0
- package/dist/command-errors.d.ts.map +1 -0
- package/dist/command-errors.js +15 -0
- package/dist/command-errors.js.map +1 -0
- package/dist/commands/__tests__/jtbd.test.d.ts +2 -0
- package/dist/commands/__tests__/jtbd.test.d.ts.map +1 -0
- package/dist/commands/__tests__/jtbd.test.js +120 -0
- package/dist/commands/__tests__/jtbd.test.js.map +1 -0
- package/dist/commands/__tests__/timeline-render-audio.test.d.ts +2 -0
- package/dist/commands/__tests__/timeline-render-audio.test.d.ts.map +1 -0
- package/dist/commands/__tests__/timeline-render-audio.test.js +53 -0
- package/dist/commands/__tests__/timeline-render-audio.test.js.map +1 -0
- package/dist/commands/__tests__/timeline-render-completeness.test.d.ts +2 -0
- package/dist/commands/__tests__/timeline-render-completeness.test.d.ts.map +1 -0
- package/dist/commands/__tests__/timeline-render-completeness.test.js +117 -0
- package/dist/commands/__tests__/timeline-render-completeness.test.js.map +1 -0
- package/dist/commands/__tests__/timeline-render.test.d.ts +2 -0
- package/dist/commands/__tests__/timeline-render.test.d.ts.map +1 -0
- package/dist/commands/__tests__/timeline-render.test.js +115 -0
- package/dist/commands/__tests__/timeline-render.test.js.map +1 -0
- package/dist/commands/__tests__/timeline-score.test.d.ts +2 -0
- package/dist/commands/__tests__/timeline-score.test.d.ts.map +1 -0
- package/dist/commands/__tests__/timeline-score.test.js +100 -0
- package/dist/commands/__tests__/timeline-score.test.js.map +1 -0
- package/dist/commands/affected.d.ts +9 -0
- package/dist/commands/affected.d.ts.map +1 -0
- package/dist/commands/affected.js +122 -0
- package/dist/commands/affected.js.map +1 -0
- package/dist/commands/agent.d.ts +26 -4
- package/dist/commands/agent.d.ts.map +1 -1
- package/dist/commands/agent.js +328 -306
- package/dist/commands/agent.js.map +1 -1
- package/dist/commands/app.d.ts +3 -0
- package/dist/commands/app.d.ts.map +1 -0
- package/dist/commands/app.js +405 -0
- package/dist/commands/app.js.map +1 -0
- package/dist/commands/apps.d.ts +15 -0
- package/dist/commands/apps.d.ts.map +1 -0
- package/dist/commands/apps.js +180 -0
- package/dist/commands/apps.js.map +1 -0
- package/dist/commands/auth.d.ts +12 -0
- package/dist/commands/auth.d.ts.map +1 -0
- package/dist/commands/auth.js +154 -0
- package/dist/commands/auth.js.map +1 -0
- package/dist/commands/collections.d.ts +10 -0
- package/dist/commands/collections.d.ts.map +1 -0
- package/dist/commands/collections.js +257 -0
- package/dist/commands/collections.js.map +1 -0
- package/dist/commands/costs.d.ts +15 -0
- package/dist/commands/costs.d.ts.map +1 -0
- package/dist/commands/costs.js +201 -0
- package/dist/commands/costs.js.map +1 -0
- package/dist/commands/db.d.ts +3 -0
- package/dist/commands/db.d.ts.map +1 -0
- package/dist/commands/db.js +176 -0
- package/dist/commands/db.js.map +1 -0
- package/dist/commands/debug-summary-output.d.ts +22 -0
- package/dist/commands/debug-summary-output.d.ts.map +1 -0
- package/dist/commands/debug-summary-output.js +28 -0
- package/dist/commands/debug-summary-output.js.map +1 -0
- package/dist/commands/debug.d.ts +13 -0
- package/dist/commands/debug.d.ts.map +1 -0
- package/dist/commands/debug.js +138 -0
- package/dist/commands/debug.js.map +1 -0
- package/dist/commands/deploy-helpers.d.ts +49 -18
- package/dist/commands/deploy-helpers.d.ts.map +1 -1
- package/dist/commands/deploy-helpers.js +10 -276
- package/dist/commands/deploy-helpers.js.map +1 -1
- package/dist/commands/deploy.d.ts +0 -1
- package/dist/commands/deploy.d.ts.map +1 -1
- package/dist/commands/deploy.js +21 -217
- package/dist/commands/deploy.js.map +1 -1
- package/dist/commands/errors.d.ts +11 -0
- package/dist/commands/errors.d.ts.map +1 -0
- package/dist/commands/errors.js +177 -0
- package/dist/commands/errors.js.map +1 -0
- package/dist/commands/eval.d.ts +152 -0
- package/dist/commands/eval.d.ts.map +1 -0
- package/dist/commands/eval.js +690 -0
- package/dist/commands/eval.js.map +1 -0
- package/dist/commands/extension.d.ts +12 -0
- package/dist/commands/extension.d.ts.map +1 -0
- package/dist/commands/extension.js +30 -0
- package/dist/commands/extension.js.map +1 -0
- package/dist/commands/game-benchmark.d.ts +34 -0
- package/dist/commands/game-benchmark.d.ts.map +1 -0
- package/dist/commands/game-benchmark.js +95 -0
- package/dist/commands/game-benchmark.js.map +1 -0
- package/dist/commands/game-smoke.d.ts +3 -0
- package/dist/commands/game-smoke.d.ts.map +1 -0
- package/dist/commands/game-smoke.js +23 -0
- package/dist/commands/game-smoke.js.map +1 -0
- package/dist/commands/game.d.ts +4 -0
- package/dist/commands/game.d.ts.map +1 -0
- package/dist/commands/game.js +624 -0
- package/dist/commands/game.js.map +1 -0
- package/dist/commands/generate.d.ts +17 -0
- package/dist/commands/generate.d.ts.map +1 -0
- package/dist/commands/generate.js +324 -0
- package/dist/commands/generate.js.map +1 -0
- package/dist/commands/generations.d.ts +17 -0
- package/dist/commands/generations.d.ts.map +1 -0
- package/dist/commands/generations.js +408 -0
- package/dist/commands/generations.js.map +1 -0
- package/dist/commands/harness.d.ts +69 -0
- package/dist/commands/harness.d.ts.map +1 -0
- package/dist/commands/harness.js +575 -0
- package/dist/commands/harness.js.map +1 -0
- package/dist/commands/js-script-validation-output.d.ts +7 -0
- package/dist/commands/js-script-validation-output.d.ts.map +1 -0
- package/dist/commands/js-script-validation-output.js +5 -0
- package/dist/commands/js-script-validation-output.js.map +1 -0
- package/dist/commands/js-script-versions.d.ts +53 -0
- package/dist/commands/js-script-versions.d.ts.map +1 -0
- package/dist/commands/js-script-versions.js +89 -0
- package/dist/commands/js-script-versions.js.map +1 -0
- package/dist/commands/js-script.d.ts +29 -0
- package/dist/commands/js-script.d.ts.map +1 -0
- package/dist/commands/js-script.js +211 -0
- package/dist/commands/js-script.js.map +1 -0
- package/dist/commands/jtbd.d.ts +38 -0
- package/dist/commands/jtbd.d.ts.map +1 -0
- package/dist/commands/jtbd.js +261 -0
- package/dist/commands/jtbd.js.map +1 -0
- package/dist/commands/local-db.d.ts +16 -0
- package/dist/commands/local-db.d.ts.map +1 -0
- package/dist/commands/local-db.js +33 -0
- package/dist/commands/local-db.js.map +1 -0
- package/dist/commands/mcp.d.ts +21 -0
- package/dist/commands/mcp.d.ts.map +1 -0
- package/dist/commands/mcp.js +164 -0
- package/dist/commands/mcp.js.map +1 -0
- package/dist/commands/migrate-code-inputs.d.ts +24 -0
- package/dist/commands/migrate-code-inputs.d.ts.map +1 -0
- package/dist/commands/migrate-code-inputs.js +120 -0
- package/dist/commands/migrate-code-inputs.js.map +1 -0
- package/dist/commands/models-hf.js +4 -4
- package/dist/commands/models-hf.js.map +1 -1
- package/dist/commands/models-recommended.d.ts.map +1 -1
- package/dist/commands/models-recommended.js +16 -24
- package/dist/commands/models-recommended.js.map +1 -1
- package/dist/commands/node.d.ts +10 -0
- package/dist/commands/node.d.ts.map +1 -0
- package/dist/commands/node.js +72 -0
- package/dist/commands/node.js.map +1 -0
- package/dist/commands/output.d.ts +24 -0
- package/dist/commands/output.d.ts.map +1 -0
- package/dist/commands/output.js +132 -0
- package/dist/commands/output.js.map +1 -0
- package/dist/commands/package-helpers.d.ts +1 -7
- package/dist/commands/package-helpers.d.ts.map +1 -1
- package/dist/commands/package-helpers.js +3 -26
- package/dist/commands/package-helpers.js.map +1 -1
- package/dist/commands/package.d.ts.map +1 -1
- package/dist/commands/package.js +14 -14
- package/dist/commands/package.js.map +1 -1
- package/dist/commands/packs.d.ts +13 -0
- package/dist/commands/packs.d.ts.map +1 -0
- package/dist/commands/packs.js +60 -0
- package/dist/commands/packs.js.map +1 -0
- package/dist/commands/reliability.d.ts +14 -0
- package/dist/commands/reliability.d.ts.map +1 -0
- package/dist/commands/reliability.js +80 -0
- package/dist/commands/reliability.js.map +1 -0
- package/dist/commands/resource-read.d.ts +28 -0
- package/dist/commands/resource-read.d.ts.map +1 -0
- package/dist/commands/resource-read.js +316 -0
- package/dist/commands/resource-read.js.map +1 -0
- package/dist/commands/runs.d.ts +7 -0
- package/dist/commands/runs.d.ts.map +1 -0
- package/dist/commands/runs.js +302 -0
- package/dist/commands/runs.js.map +1 -0
- package/dist/commands/sketch-validation-output.d.ts +7 -0
- package/dist/commands/sketch-validation-output.d.ts.map +1 -0
- package/dist/commands/sketch-validation-output.js +5 -0
- package/dist/commands/sketch-validation-output.js.map +1 -0
- package/dist/commands/sketch-versions.d.ts +66 -0
- package/dist/commands/sketch-versions.d.ts.map +1 -0
- package/dist/commands/sketch-versions.js +108 -0
- package/dist/commands/sketch-versions.js.map +1 -0
- package/dist/commands/sketch.d.ts +21 -0
- package/dist/commands/sketch.d.ts.map +1 -0
- package/dist/commands/sketch.js +101 -0
- package/dist/commands/sketch.js.map +1 -0
- package/dist/commands/storage.d.ts +24 -0
- package/dist/commands/storage.d.ts.map +1 -0
- package/dist/commands/storage.js +112 -0
- package/dist/commands/storage.js.map +1 -0
- package/dist/commands/telegram.d.ts +11 -0
- package/dist/commands/telegram.d.ts.map +1 -0
- package/dist/commands/telegram.js +66 -0
- package/dist/commands/telegram.js.map +1 -0
- package/dist/commands/timeline-render.d.ts +85 -0
- package/dist/commands/timeline-render.d.ts.map +1 -0
- package/dist/commands/timeline-render.js +474 -0
- package/dist/commands/timeline-render.js.map +1 -0
- package/dist/commands/timeline-score.d.ts +16 -0
- package/dist/commands/timeline-score.d.ts.map +1 -0
- package/dist/commands/timeline-score.js +89 -0
- package/dist/commands/timeline-score.js.map +1 -0
- package/dist/commands/timeline-validation-output.d.ts +7 -0
- package/dist/commands/timeline-validation-output.d.ts.map +1 -0
- package/dist/commands/timeline-validation-output.js +9 -0
- package/dist/commands/timeline-validation-output.js.map +1 -0
- package/dist/commands/timeline-versions.d.ts +72 -0
- package/dist/commands/timeline-versions.d.ts.map +1 -0
- package/dist/commands/timeline-versions.js +108 -0
- package/dist/commands/timeline-versions.js.map +1 -0
- package/dist/commands/timeline.d.ts +22 -0
- package/dist/commands/timeline.d.ts.map +1 -0
- package/dist/commands/timeline.js +105 -0
- package/dist/commands/timeline.js.map +1 -0
- package/dist/commands/validate.d.ts +22 -0
- package/dist/commands/validate.d.ts.map +1 -0
- package/dist/commands/validate.js +127 -0
- package/dist/commands/validate.js.map +1 -0
- package/dist/commands/validation-output.d.ts +25 -0
- package/dist/commands/validation-output.d.ts.map +1 -0
- package/dist/commands/validation-output.js +29 -0
- package/dist/commands/validation-output.js.map +1 -0
- package/dist/commands/version-commands.d.ts +94 -0
- package/dist/commands/version-commands.d.ts.map +1 -0
- package/dist/commands/version-commands.js +227 -0
- package/dist/commands/version-commands.js.map +1 -0
- package/dist/commands/worker-models.d.ts +13 -0
- package/dist/commands/worker-models.d.ts.map +1 -0
- package/dist/commands/worker-models.js +207 -0
- package/dist/commands/worker-models.js.map +1 -0
- package/dist/commands/worker.d.ts +23 -0
- package/dist/commands/worker.d.ts.map +1 -0
- package/dist/commands/worker.js +374 -0
- package/dist/commands/worker.js.map +1 -0
- package/dist/debug/browser-runner.d.ts +21 -0
- package/dist/debug/browser-runner.d.ts.map +1 -0
- package/dist/debug/browser-runner.js +196 -0
- package/dist/debug/browser-runner.js.map +1 -0
- package/dist/debug/collector.d.ts +9 -0
- package/dist/debug/collector.d.ts.map +1 -0
- package/dist/debug/collector.js +9 -0
- package/dist/debug/collector.js.map +1 -0
- package/dist/debug/diff.d.ts +48 -0
- package/dist/debug/diff.d.ts.map +1 -0
- package/dist/debug/diff.js +68 -0
- package/dist/debug/diff.js.map +1 -0
- package/dist/debug/harness.d.ts +11 -0
- package/dist/debug/harness.d.ts.map +1 -0
- package/dist/debug/harness.js +103 -0
- package/dist/debug/harness.js.map +1 -0
- package/dist/debug/index.d.ts +17 -0
- package/dist/debug/index.d.ts.map +1 -0
- package/dist/debug/index.js +16 -0
- package/dist/debug/index.js.map +1 -0
- package/dist/debug/markdown.d.ts +3 -0
- package/dist/debug/markdown.d.ts.map +1 -0
- package/dist/debug/markdown.js +127 -0
- package/dist/debug/markdown.js.map +1 -0
- package/dist/debug/server-runner.d.ts +24 -0
- package/dist/debug/server-runner.d.ts.map +1 -0
- package/dist/debug/server-runner.js +197 -0
- package/dist/debug/server-runner.js.map +1 -0
- package/dist/debug/target.d.ts +34 -0
- package/dist/debug/target.d.ts.map +1 -0
- package/dist/debug/target.js +104 -0
- package/dist/debug/target.js.map +1 -0
- package/dist/debug/trace.d.ts +30 -0
- package/dist/debug/trace.d.ts.map +1 -0
- package/dist/debug/trace.js +87 -0
- package/dist/debug/trace.js.map +1 -0
- package/dist/debug/types.d.ts +82 -0
- package/dist/debug/types.d.ts.map +1 -0
- package/dist/debug/types.js +13 -0
- package/dist/debug/types.js.map +1 -0
- package/dist/debug/verdict.d.ts +3 -0
- package/dist/debug/verdict.d.ts.map +1 -0
- package/dist/debug/verdict.js +78 -0
- package/dist/debug/verdict.js.map +1 -0
- package/dist/debug/watch.d.ts +23 -0
- package/dist/debug/watch.d.ts.map +1 -0
- package/dist/debug/watch.js +68 -0
- package/dist/debug/watch.js.map +1 -0
- package/dist/diagnose.d.ts +139 -0
- package/dist/diagnose.d.ts.map +1 -0
- package/dist/diagnose.js +418 -0
- package/dist/diagnose.js.map +1 -0
- package/dist/evals/graph-runner.d.ts +8 -0
- package/dist/evals/graph-runner.d.ts.map +1 -0
- package/dist/evals/graph-runner.js +136 -0
- package/dist/evals/graph-runner.js.map +1 -0
- package/dist/harness/capability-coverage.d.ts +161 -0
- package/dist/harness/capability-coverage.d.ts.map +1 -0
- package/dist/harness/capability-coverage.js +266 -0
- package/dist/harness/capability-coverage.js.map +1 -0
- package/dist/harness/capability-table.d.ts +17 -0
- package/dist/harness/capability-table.d.ts.map +1 -0
- package/dist/harness/capability-table.js +3844 -0
- package/dist/harness/capability-table.js.map +1 -0
- package/dist/harness/changed-files.d.ts +20 -0
- package/dist/harness/changed-files.d.ts.map +1 -0
- package/dist/harness/changed-files.js +90 -0
- package/dist/harness/changed-files.js.map +1 -0
- package/dist/harness/declared-capabilities.d.ts +12 -0
- package/dist/harness/declared-capabilities.d.ts.map +1 -0
- package/dist/harness/declared-capabilities.js +21 -0
- package/dist/harness/declared-capabilities.js.map +1 -0
- package/dist/harness/registry.d.ts +190 -0
- package/dist/harness/registry.d.ts.map +1 -0
- package/dist/harness/registry.js +2034 -0
- package/dist/harness/registry.js.map +1 -0
- package/dist/index.js +122 -131
- package/dist/index.js.map +1 -1
- package/dist/interaction-script.d.ts +40 -0
- package/dist/interaction-script.d.ts.map +1 -0
- package/dist/interaction-script.js +96 -0
- package/dist/interaction-script.js.map +1 -0
- package/dist/js-script-debug/harness.d.ts +124 -0
- package/dist/js-script-debug/harness.d.ts.map +1 -0
- package/dist/js-script-debug/harness.js +230 -0
- package/dist/js-script-debug/harness.js.map +1 -0
- package/dist/js-script-debug/index.d.ts +9 -0
- package/dist/js-script-debug/index.d.ts.map +1 -0
- package/dist/js-script-debug/index.js +9 -0
- package/dist/js-script-debug/index.js.map +1 -0
- package/dist/js-script-debug/interactions.d.ts +19 -0
- package/dist/js-script-debug/interactions.d.ts.map +1 -0
- package/dist/js-script-debug/interactions.js +17 -0
- package/dist/js-script-debug/interactions.js.map +1 -0
- package/dist/js-script-debug/target.d.ts +20 -0
- package/dist/js-script-debug/target.d.ts.map +1 -0
- package/dist/js-script-debug/target.js +78 -0
- package/dist/js-script-debug/target.js.map +1 -0
- package/dist/local-model-interfaces.d.ts +20 -0
- package/dist/local-model-interfaces.d.ts.map +1 -0
- package/dist/local-model-interfaces.js +41 -0
- package/dist/local-model-interfaces.js.map +1 -0
- package/dist/local-secrets.d.ts +3 -0
- package/dist/local-secrets.d.ts.map +1 -0
- package/dist/local-secrets.js +16 -0
- package/dist/local-secrets.js.map +1 -0
- package/dist/markdown.d.ts.map +1 -1
- package/dist/markdown.js +7 -2
- package/dist/markdown.js.map +1 -1
- package/dist/node/run-node.d.ts +28 -0
- package/dist/node/run-node.d.ts.map +1 -0
- package/dist/node/run-node.js +76 -0
- package/dist/node/run-node.js.map +1 -0
- package/dist/node-registry.d.ts +27 -0
- package/dist/node-registry.d.ts.map +1 -0
- package/dist/node-registry.js +33 -0
- package/dist/node-registry.js.map +1 -0
- package/dist/nodetool-main.d.ts +15 -0
- package/dist/nodetool-main.d.ts.map +1 -0
- package/dist/nodetool-main.js +1368 -0
- package/dist/nodetool-main.js.map +1 -0
- package/dist/nodetool.d.ts +0 -13
- package/dist/nodetool.d.ts.map +1 -1
- package/dist/nodetool.js +17 -1147
- package/dist/nodetool.js.map +1 -1
- package/dist/numeric-options.d.ts +22 -0
- package/dist/numeric-options.d.ts.map +1 -0
- package/dist/numeric-options.js +45 -0
- package/dist/numeric-options.js.map +1 -0
- package/dist/permission-gate.d.ts +55 -0
- package/dist/permission-gate.d.ts.map +1 -0
- package/dist/permission-gate.js +118 -0
- package/dist/permission-gate.js.map +1 -0
- package/dist/predicates.d.ts +6 -0
- package/dist/predicates.d.ts.map +1 -0
- package/dist/predicates.js +6 -0
- package/dist/predicates.js.map +1 -0
- package/dist/providers.d.ts +73 -10
- package/dist/providers.d.ts.map +1 -1
- package/dist/providers.js +339 -97
- package/dist/providers.js.map +1 -1
- package/dist/readline-input.d.ts +13 -19
- package/dist/readline-input.d.ts.map +1 -1
- package/dist/readline-input.js +201 -190
- package/dist/readline-input.js.map +1 -1
- package/dist/run-budget.d.ts +40 -0
- package/dist/run-budget.d.ts.map +1 -0
- package/dist/run-budget.js +119 -0
- package/dist/run-budget.js.map +1 -0
- package/dist/run-dsl-supervised.d.ts +11 -0
- package/dist/run-dsl-supervised.d.ts.map +1 -0
- package/dist/run-dsl-supervised.js +82 -0
- package/dist/run-dsl-supervised.js.map +1 -0
- package/dist/run-dsl.d.ts +29 -0
- package/dist/run-dsl.d.ts.map +1 -1
- package/dist/run-dsl.js +44 -10
- package/dist/run-dsl.js.map +1 -1
- package/dist/run-json.d.ts +24 -0
- package/dist/run-json.d.ts.map +1 -0
- package/dist/run-json.js +132 -0
- package/dist/run-json.js.map +1 -0
- package/dist/sandbox-catalog.d.ts +24 -0
- package/dist/sandbox-catalog.d.ts.map +1 -0
- package/dist/sandbox-catalog.js +78 -0
- package/dist/sandbox-catalog.js.map +1 -0
- package/dist/settings.d.ts +11 -10
- package/dist/settings.d.ts.map +1 -1
- package/dist/settings.js +71 -13
- package/dist/settings.js.map +1 -1
- package/dist/sketch-debug/harness.d.ts +87 -0
- package/dist/sketch-debug/harness.d.ts.map +1 -0
- package/dist/sketch-debug/harness.js +145 -0
- package/dist/sketch-debug/harness.js.map +1 -0
- package/dist/sketch-debug/index.d.ts +9 -0
- package/dist/sketch-debug/index.d.ts.map +1 -0
- package/dist/sketch-debug/index.js +9 -0
- package/dist/sketch-debug/index.js.map +1 -0
- package/dist/sketch-debug/interactions.d.ts +19 -0
- package/dist/sketch-debug/interactions.d.ts.map +1 -0
- package/dist/sketch-debug/interactions.js +17 -0
- package/dist/sketch-debug/interactions.js.map +1 -0
- package/dist/sketch-debug/target.d.ts +48 -0
- package/dist/sketch-debug/target.d.ts.map +1 -0
- package/dist/sketch-debug/target.js +138 -0
- package/dist/sketch-debug/target.js.map +1 -0
- package/dist/stdin.d.ts +18 -19
- package/dist/stdin.d.ts.map +1 -1
- package/dist/stdin.js +160 -157
- package/dist/stdin.js.map +1 -1
- package/dist/supervisor.d.ts +97 -0
- package/dist/supervisor.d.ts.map +1 -0
- package/dist/supervisor.js +194 -0
- package/dist/supervisor.js.map +1 -0
- package/dist/terminal-clipboard.d.ts +3 -0
- package/dist/terminal-clipboard.d.ts.map +1 -0
- package/dist/terminal-clipboard.js +24 -0
- package/dist/terminal-clipboard.js.map +1 -0
- package/dist/terminal-mouse.d.ts +24 -0
- package/dist/terminal-mouse.d.ts.map +1 -0
- package/dist/terminal-mouse.js +84 -0
- package/dist/terminal-mouse.js.map +1 -0
- package/dist/terminal-screen.d.ts +41 -0
- package/dist/terminal-screen.d.ts.map +1 -0
- package/dist/terminal-screen.js +228 -0
- package/dist/terminal-screen.js.map +1 -0
- package/dist/timeline-debug/harness.d.ts +79 -0
- package/dist/timeline-debug/harness.d.ts.map +1 -0
- package/dist/timeline-debug/harness.js +122 -0
- package/dist/timeline-debug/harness.js.map +1 -0
- package/dist/timeline-debug/index.d.ts +9 -0
- package/dist/timeline-debug/index.d.ts.map +1 -0
- package/dist/timeline-debug/index.js +9 -0
- package/dist/timeline-debug/index.js.map +1 -0
- package/dist/timeline-debug/interactions.d.ts +19 -0
- package/dist/timeline-debug/interactions.d.ts.map +1 -0
- package/dist/timeline-debug/interactions.js +17 -0
- package/dist/timeline-debug/interactions.js.map +1 -0
- package/dist/timeline-debug/target.d.ts +34 -0
- package/dist/timeline-debug/target.d.ts.map +1 -0
- package/dist/timeline-debug/target.js +132 -0
- package/dist/timeline-debug/target.js.map +1 -0
- package/dist/tool-format.d.ts +54 -0
- package/dist/tool-format.d.ts.map +1 -0
- package/dist/tool-format.js +360 -0
- package/dist/tool-format.js.map +1 -0
- package/dist/useExecutionState.d.ts.map +1 -1
- package/dist/useExecutionState.js +8 -4
- package/dist/useExecutionState.js.map +1 -1
- package/dist/validate/index.d.ts +28 -0
- package/dist/validate/index.d.ts.map +1 -0
- package/dist/validate/index.js +51 -0
- package/dist/validate/index.js.map +1 -0
- package/dist/websocket-client.d.ts +78 -15
- package/dist/websocket-client.d.ts.map +1 -1
- package/dist/websocket-client.js +497 -171
- package/dist/websocket-client.js.map +1 -1
- package/package.json +65 -31
|
@@ -0,0 +1,120 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Resolves an app debug target into an application document plus the graphs it
|
|
3
|
+
* runs.
|
|
4
|
+
*
|
|
5
|
+
* An app can be named three ways, and all three end up in the same shape:
|
|
6
|
+
*
|
|
7
|
+
* - an **application id** — the canonical form, read from the applications
|
|
8
|
+
* table through an injected loader (no server involved) and resolved by
|
|
9
|
+
* `applicationTarget`, which the server surface calls too;
|
|
10
|
+
* - an **ApplicationBundle JSON file** — an app together with the full graphs
|
|
11
|
+
* of every workflow it binds, where operations reference bundle-local keys;
|
|
12
|
+
* - a **workflow id or workflow JSON/DSL file** — the legacy form, where the
|
|
13
|
+
* document sits on `workflow.app_doc` and is lifted by `liftLegacyAppDoc`.
|
|
14
|
+
*
|
|
15
|
+
* The harness downstream sees one shape regardless: a raw document (for the
|
|
16
|
+
* bundle's `app.json` and persist-downgrade warnings), the parsed document, a
|
|
17
|
+
* host graph, and the graphs the target itself carries keyed by whatever id
|
|
18
|
+
* the operations reference.
|
|
19
|
+
*/
|
|
20
|
+
import { liftLegacyAppDoc, parseApplicationBundle } from "@nodetool-ai/app-runtime";
|
|
21
|
+
import { looksLikeFile, normalizeGraph, readFileTarget } from "../debug/target.js";
|
|
22
|
+
// The resolved shape is the simulator's input, and so is the resolution of an
|
|
23
|
+
// application row — both live with the simulator so the CLI and the server
|
|
24
|
+
// surfaces cannot drift.
|
|
25
|
+
import { applicationTarget, bundleTarget } from "@nodetool-ai/execution/app-debug";
|
|
26
|
+
import { isRecord, isString } from "../predicates.js";
|
|
27
|
+
const EMPTY_GRAPH = { nodes: [], edges: [] };
|
|
28
|
+
const targetInfo = (ref, source, workflowId, graph) => ({
|
|
29
|
+
ref,
|
|
30
|
+
source,
|
|
31
|
+
workflowId,
|
|
32
|
+
nodeCount: graph.nodes.length,
|
|
33
|
+
edgeCount: graph.edges.length
|
|
34
|
+
});
|
|
35
|
+
/** A bundle file carries `app` and `workflows`; a workflow file carries neither. */
|
|
36
|
+
const looksLikeBundle = (raw) => isRecord(raw) && isRecord(raw.app) && Array.isArray(raw.workflows);
|
|
37
|
+
const graphOf = (value) => {
|
|
38
|
+
if (!isRecord(value))
|
|
39
|
+
return null;
|
|
40
|
+
const { nodes, edges } = value;
|
|
41
|
+
if (!Array.isArray(nodes) || !Array.isArray(edges))
|
|
42
|
+
return null;
|
|
43
|
+
return normalizeGraph({ nodes, edges });
|
|
44
|
+
};
|
|
45
|
+
/** Resolve an ApplicationBundle JSON file. */
|
|
46
|
+
function resolveBundle(ref, raw) {
|
|
47
|
+
const bundle = parseApplicationBundle(raw);
|
|
48
|
+
const rawApp = isRecord(raw) ? raw.app : null;
|
|
49
|
+
if (!bundle) {
|
|
50
|
+
return {
|
|
51
|
+
info: targetInfo(ref, "bundle", null, EMPTY_GRAPH),
|
|
52
|
+
graph: EMPTY_GRAPH,
|
|
53
|
+
fileParams: {},
|
|
54
|
+
appDoc: rawApp,
|
|
55
|
+
document: null,
|
|
56
|
+
issue: `${ref} is not a valid application bundle (no parsable \`app\` document).`,
|
|
57
|
+
graphs: new Map(),
|
|
58
|
+
operationsReferenceKeys: true,
|
|
59
|
+
appName: null
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
// The bundle → target mapping lives with the simulator, so the file path
|
|
63
|
+
// here and the build harness's in-memory path cannot drift.
|
|
64
|
+
return bundleTarget(bundle, ref, rawApp);
|
|
65
|
+
}
|
|
66
|
+
/** Resolve a workflow target — id, JSON file, or DSL file — via its `app_doc`. */
|
|
67
|
+
function resolveWorkflow(ref, raw, source) {
|
|
68
|
+
const record = isRecord(raw) ? raw : {};
|
|
69
|
+
const workflowId = (isString(record.workflow_id) ? record.workflow_id : null) ??
|
|
70
|
+
(isString(record.id) ? record.id : null);
|
|
71
|
+
const rawGraph = graphOf(record.graph) ?? graphOf(record);
|
|
72
|
+
if (!rawGraph)
|
|
73
|
+
throw new Error("Invalid workflow: missing nodes or edges");
|
|
74
|
+
const appDoc = record.app_doc ?? null;
|
|
75
|
+
const document = liftLegacyAppDoc({ id: workflowId ?? "", app_doc: appDoc });
|
|
76
|
+
const graphs = new Map();
|
|
77
|
+
if (workflowId)
|
|
78
|
+
graphs.set(workflowId, rawGraph);
|
|
79
|
+
const issue = document
|
|
80
|
+
? null
|
|
81
|
+
: appDoc == null
|
|
82
|
+
? "Workflow has no app_doc — build the app in the App Builder first."
|
|
83
|
+
: "app_doc is not a valid application document (no `ui`/`data`).";
|
|
84
|
+
return {
|
|
85
|
+
info: targetInfo(ref, source, workflowId, rawGraph),
|
|
86
|
+
graph: rawGraph,
|
|
87
|
+
fileParams: isRecord(record.params) ? { ...record.params } : {},
|
|
88
|
+
appDoc,
|
|
89
|
+
document,
|
|
90
|
+
issue,
|
|
91
|
+
graphs,
|
|
92
|
+
operationsReferenceKeys: false,
|
|
93
|
+
appName: null
|
|
94
|
+
};
|
|
95
|
+
}
|
|
96
|
+
/**
|
|
97
|
+
* Resolve an app debug target: an application id, an ApplicationBundle JSON
|
|
98
|
+
* file, or a workflow id / workflow file carrying a legacy `app_doc`.
|
|
99
|
+
*/
|
|
100
|
+
export async function resolveAppTarget(ref, deps) {
|
|
101
|
+
if (looksLikeFile(ref)) {
|
|
102
|
+
const { raw, source } = await readFileTarget(ref);
|
|
103
|
+
return looksLikeBundle(raw)
|
|
104
|
+
? resolveBundle(ref, raw)
|
|
105
|
+
: resolveWorkflow(ref, raw, source);
|
|
106
|
+
}
|
|
107
|
+
if (deps.loadApplication) {
|
|
108
|
+
const application = await deps.loadApplication(ref);
|
|
109
|
+
if (application)
|
|
110
|
+
return applicationTarget(ref, application, deps.loadFromDb);
|
|
111
|
+
}
|
|
112
|
+
const workflow = await deps.loadFromDb(ref);
|
|
113
|
+
if (!workflow) {
|
|
114
|
+
throw new Error(deps.loadApplication
|
|
115
|
+
? `No application or workflow found: ${ref}`
|
|
116
|
+
: `Workflow not found: ${ref}`);
|
|
117
|
+
}
|
|
118
|
+
return resolveWorkflow(ref, { ...workflow, id: ref }, "id");
|
|
119
|
+
}
|
|
120
|
+
//# sourceMappingURL=app-target.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"app-target.js","sourceRoot":"","sources":["../../src/app-debug/app-target.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AACH,OAAO,EACL,gBAAgB,EAChB,sBAAsB,EACvB,MAAM,0BAA0B,CAAC;AAElC,OAAO,EAAE,aAAa,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAEnF,8EAA8E;AAC9E,2EAA2E;AAC3E,yBAAyB;AACzB,OAAO,EACL,iBAAiB,EACjB,YAAY,EAIb,MAAM,kCAAkC,CAAC;AAC1C,OAAO,EACL,QAAQ,EACR,QAAQ,EACT,MAAM,kBAAkB,CAAC;AAW1B,MAAM,WAAW,GAAe,EAAE,KAAK,EAAE,EAAE,EAAE,KAAK,EAAE,EAAE,EAAE,CAAC;AAEzD,MAAM,UAAU,GAAG,CACjB,GAAW,EACX,MAAiC,EACjC,UAAyB,EACzB,KAAiB,EACA,EAAE,CAAC,CAAC;IACrB,GAAG;IACH,MAAM;IACN,UAAU;IACV,SAAS,EAAE,KAAK,CAAC,KAAK,CAAC,MAAM;IAC7B,SAAS,EAAE,KAAK,CAAC,KAAK,CAAC,MAAM;CAC9B,CAAC,CAAC;AAEH,oFAAoF;AACpF,MAAM,eAAe,GAAG,CAAC,GAAY,EAAW,EAAE,CAChD,QAAQ,CAAC,GAAG,CAAC,IAAI,QAAQ,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,KAAK,CAAC,OAAO,CAAC,GAAG,CAAC,SAAS,CAAC,CAAC;AAErE,MAAM,OAAO,GAAG,CAAC,KAAc,EAAqB,EAAE;IACpD,IAAI,CAAC,QAAQ,CA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AGG;AACH,MAAM,CAAC,KAAK,UAAU,gBAAgB,CACpC,GAAW,EACX,IAAmB;IAEnB,IAAI,aAAa,CAAC,GAAG,CAAC,EAAE,CAAC;QACvB,MAAM,EAAE,GAAG,EAAE,MAAM,EAAE,GAAG,MAAM,cAAc,CAAC,GAAG,CAAC,CAAC;QAClD,OAAO,eAAe,CAAC,GAAG,CAAC;YACzB,CAAC,CAAC,aAAa,CAAC,GAAG,EAAE,GAAG,CAAC;YACzB,CAAC,CAAC,eAAe,CAAC,GAAG,EAAE,GAAG,EAAE,MAAM,CAAC,CAAC;IACxC,CAAC;IAED,IAAI,IAAI,CAAC,eAAe,EAAE,CAAC;QACzB,MAAM,WAAW,GAAG,MAAM,IAAI,CAAC,eAAe,CAAC,GAAG,CAAC,CAAC;QACpD,IAAI,WAAW;YAAE,OAAO,iBAAiB,CAAC,GAAG,EAAE,WAAW,EAAE,IAAI,CAAC,UAAU,CAAC,CAAC;IAC/E,CAAC;IAED,MAAM,QAAQ,GAAG,MAAM,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC;IAC5C,IAAI,CAAC,QAAQ,EAAE,CAAC;QACd,MAAM,IAAI,KAAK,CACb,IAAI,CAAC,eAAe;YAClB,CAAC,CAAC,qCAAqC,GAAG,EAAE;YAC5C,CAAC,CAAC,uBAAuB,GAAG,EAAE,CACjC,CAAC;IACJ,CAAC;IACD,OAAO,eAAe,CAAC,GAAG,EAAE,EAAE,GAAG,QAAQ,EAAE,EAAE,EAAE,GAAG,EAAE,EAAE,IAAI,CAAC,CAAC;AAC9D,CAAC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { type AppDebugOptions, type AppDebugReport, type JsScriptOperationLoader, type JsScriptOperationRunner } from "@nodetool-ai/execution/app-debug";
|
|
2
|
+
import type { NodeRegistry } from "@nodetool-ai/node-sdk";
|
|
3
|
+
import { type AppTargetDeps } from "./app-target.js";
|
|
4
|
+
import type { DebugGraph } from "../debug/types.js";
|
|
5
|
+
import type { ServerRunInput, ServerRunOutcome } from "../debug/server-runner.js";
|
|
6
|
+
export { defaultInteractions } from "@nodetool-ai/execution/app-debug";
|
|
7
|
+
export interface AppDebugDeps {
|
|
8
|
+
/** Load a workflow by DB id, including its legacy `app_doc`. */
|
|
9
|
+
loadFromDb: (id: string, version?: number) => Promise<{
|
|
10
|
+
graph: DebugGraph;
|
|
11
|
+
app_doc?: unknown;
|
|
12
|
+
} | null>;
|
|
13
|
+
/**
|
|
14
|
+
* Load an application by DB id. Without it a bare id is only ever read as a
|
|
15
|
+
* workflow, which is what a caller with no database wants.
|
|
16
|
+
*/
|
|
17
|
+
loadApplication?: AppTargetDeps["loadApplication"];
|
|
18
|
+
/** Progress/log sink. */
|
|
19
|
+
onLog?: (line: string) => void;
|
|
20
|
+
/** Injected for tests; defaults to the kernel server runner. */
|
|
21
|
+
runOnServer?: (input: ServerRunInput) => Promise<ServerRunOutcome>;
|
|
22
|
+
/** Injected for tests; defaults to the sandbox script runner. */
|
|
23
|
+
runScript?: JsScriptOperationRunner;
|
|
24
|
+
/** Resolve a pinned script version an operation targets but the target lacks. */
|
|
25
|
+
loadScript?: JsScriptOperationLoader;
|
|
26
|
+
registry?: NodeRegistry;
|
|
27
|
+
}
|
|
28
|
+
export declare function runAppDebug(ref: string, options: AppDebugOptions, deps: AppDebugDeps): Promise<AppDebugReport>;
|
|
29
|
+
//# sourceMappingURL=harness.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"harness.d.ts","sourceRoot":"","sources":["../../src/app-debug/harness.ts"],"names":[],"mappings":"AAYA,OAAO,EAGL,KAAK,eAAe,EACpB,KAAK,cAAc,EACnB,KAAK,uBAAuB,EAC5B,KAAK,uBAAuB,EAC7B,MAAM,kCAAkC,CAAC;AAC1C,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAG1D,OAAO,EAAoB,KAAK,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAEvE,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,mBAAmB,CAAC;AACpD,OAAO,KAAK,EACV,cAAc,EACd,gBAAgB,EACjB,MAAM,2BAA2B,CAAC;AAEnC,OAAO,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAKvE,MAAM,WAAW,YAAY;IAC3B,gEAAgE;IAChE,UAAU,EAAE,CACV,EAAE,EAAE,MAAM,EACV,OAAO,CAAC,EAAE,MAAM,KACb,OAAO,CAAC;QAAE,KAAK,EAAE,UAAU,CAAC;QAAC,OAAO,CAAC,EAAE,OAAO,CAAA;KAAE,GAAG,IAAI,CAAC,CAAC;IAC9D;;;OAGG;IACH,eAAe,CAAC,EAAE,aAAa,CAAC,iBAAiB,CAAC,CAAC;IACnD,yBAAyB;IACzB,KAAK,CAAC,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;IAC/B,gEAAgE;IAChE,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,cAAc,KAAK,OAAO,CAAC,gBAAgB,CAAC,CAAC;IACnE,iEAAiE;IACjE,SAAS,CAAC,EAAE,uBAAuB,CAAC;IACpC,iFAAiF;IACjF,UAAU,CAAC,EAAE,uBAAuB,CAAC;IACrC,QAAQ,CAAC,EAAE,YAAY,CAAC;CACzB;AAYD,wBAAsB,WAAW,CAC/B,GAAG,EAAE,MAAM,EACX,OAAO,EAAE,eAAe,EACxB,IAAI,EAAE,YAAY,GACjB,OAAO,CAAC,cAAc,CAAC,CAyHzB"}
|
|
@@ -0,0 +1,116 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The app-builder debug harness: the CLI host around the shared simulator.
|
|
3
|
+
*
|
|
4
|
+
* Resolves the target (application id, `ApplicationBundle` file, or workflow
|
|
5
|
+
* carrying a legacy `app_doc`), runs `simulateApp` from
|
|
6
|
+
* `@nodetool-ai/execution` — which owns every simulation rule — and writes the
|
|
7
|
+
* self-contained bundle: the graph, the app document, each run's raw message
|
|
8
|
+
* stream, and the report in both JSON and Markdown. The `AppDebugReport` comes
|
|
9
|
+
* back so an agent can iterate without re-reading the bundle.
|
|
10
|
+
*/
|
|
11
|
+
import { mkdir, writeFile } from "node:fs/promises";
|
|
12
|
+
import { join, resolve } from "node:path";
|
|
13
|
+
import { renderAppReportMarkdown, simulateApp } from "@nodetool-ai/execution/app-debug";
|
|
14
|
+
import { resolveAppTarget } from "./app-target.js";
|
|
15
|
+
import { formatRunJson } from "../run-json.js";
|
|
16
|
+
export { defaultInteractions } from "@nodetool-ai/execution/app-debug";
|
|
17
|
+
/** The local single-user id every direct-DB CLI command runs as. */
|
|
18
|
+
const LOCAL_USER_ID = "1";
|
|
19
|
+
function defaultOutDir(ref) {
|
|
20
|
+
const slug = ref
|
|
21
|
+
.replace(/[^a-zA-Z0-9_-]+/g, "-")
|
|
22
|
+
.replace(/^-+|-+$/g, "")
|
|
23
|
+
.slice(0, 40) || "workflow";
|
|
24
|
+
const stamp = new Date().toISOString().replace(/[:.]/g, "-");
|
|
25
|
+
return resolve(`nodetool-debug/app-${slug}-${stamp}`);
|
|
26
|
+
}
|
|
27
|
+
export async function runAppDebug(ref, options, deps) {
|
|
28
|
+
const targetDeps = {
|
|
29
|
+
loadFromDb: deps.loadFromDb
|
|
30
|
+
};
|
|
31
|
+
if (deps.loadApplication) {
|
|
32
|
+
targetDeps.loadApplication = deps.loadApplication;
|
|
33
|
+
}
|
|
34
|
+
const resolved = await resolveAppTarget(ref, targetDeps);
|
|
35
|
+
const outDir = options.outDir ? resolve(options.outDir) : defaultOutDir(ref);
|
|
36
|
+
await mkdir(join(outDir, "server"), { recursive: true });
|
|
37
|
+
await writeFile(join(outDir, "workflow.json"), JSON.stringify(resolved.graph, null, 2), "utf8");
|
|
38
|
+
if (resolved.appDoc != null) {
|
|
39
|
+
await writeFile(join(outDir, "app.json"), JSON.stringify(resolved.appDoc, null, 2), "utf8");
|
|
40
|
+
}
|
|
41
|
+
// Loaded on first run, not up front: a `--no-run` check must not pull in the
|
|
42
|
+
// node registries the server runner boots.
|
|
43
|
+
const runOnServer = deps.runOnServer ??
|
|
44
|
+
(async (input) => (await import("../debug/server-runner.js")).runOnServer(input));
|
|
45
|
+
// Both load lazily for the same reason `runOnServer` does: a `--no-run`
|
|
46
|
+
// check must not pull in the sandbox or the database.
|
|
47
|
+
const runScript = deps.runScript ??
|
|
48
|
+
(async (input) => {
|
|
49
|
+
const { createJsScriptAppRunner } = await import("@nodetool-ai/agents");
|
|
50
|
+
const { getSecret } = await import("@nodetool-ai/models");
|
|
51
|
+
return createJsScriptAppRunner(LOCAL_USER_ID, {
|
|
52
|
+
secretResolver: getSecret
|
|
53
|
+
})(input);
|
|
54
|
+
});
|
|
55
|
+
const loadScript = deps.loadScript ??
|
|
56
|
+
(async (scriptId, scriptVersion) => {
|
|
57
|
+
const { createJsScriptResolver } = await import("@nodetool-ai/models");
|
|
58
|
+
const resolved = await createJsScriptResolver().resolve({
|
|
59
|
+
id: scriptId,
|
|
60
|
+
version: scriptVersion
|
|
61
|
+
});
|
|
62
|
+
return resolved
|
|
63
|
+
? { name: resolved.name, document: resolved.document }
|
|
64
|
+
: null;
|
|
65
|
+
});
|
|
66
|
+
const simulateDeps = {
|
|
67
|
+
loadFromDb: deps.loadFromDb,
|
|
68
|
+
runOnServer,
|
|
69
|
+
runScript,
|
|
70
|
+
loadScript,
|
|
71
|
+
onRunMessages: async (runIndex, messages) => {
|
|
72
|
+
const messagesFile = `server/run-${runIndex + 1}.messages.jsonl`;
|
|
73
|
+
const lines = [];
|
|
74
|
+
for (const [messageIndex, message] of messages.entries()) {
|
|
75
|
+
const { json } = await formatRunJson(message, {
|
|
76
|
+
outputDir: join(outDir, "server", `run-${runIndex + 1}-payloads`, `message-${messageIndex + 1}`)
|
|
77
|
+
});
|
|
78
|
+
lines.push(JSON.stringify(JSON.parse(json)));
|
|
79
|
+
}
|
|
80
|
+
await writeFile(join(outDir, messagesFile), `${lines.join("\n")}\n`, "utf8");
|
|
81
|
+
return messagesFile;
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
if (deps.onLog) {
|
|
85
|
+
simulateDeps.onLog = deps.onLog;
|
|
86
|
+
}
|
|
87
|
+
const runIds = new Set();
|
|
88
|
+
if (options.run !== false) {
|
|
89
|
+
const [{ createAppDebugRunRecording }, { ProcessingContext: Context }, { buildFullRegistry }, { getSecret }, { FileStorageAdapter }, { getDefaultAssetsPath }] = await Promise.all([
|
|
90
|
+
import("@nodetool-ai/execution/app-debug"), import("@nodetool-ai/runtime"), import("../node-registry.js"),
|
|
91
|
+
import("@nodetool-ai/models"), import("@nodetool-ai/storage"), import("@nodetool-ai/config")
|
|
92
|
+
]);
|
|
93
|
+
const context = new Context({ userId: LOCAL_USER_ID, jobId: `app-debug-${Date.now()}`,
|
|
94
|
+
secretResolver: getSecret, storage: new FileStorageAdapter(getDefaultAssetsPath()) });
|
|
95
|
+
const recording = createAppDebugRunRecording({ userId: LOCAL_USER_ID, target: resolved,
|
|
96
|
+
context, registry: deps.registry ?? buildFullRegistry(), loadWorkflow: deps.loadFromDb, loadScript,
|
|
97
|
+
onRunCreated: (id) => { runIds.add(id); },
|
|
98
|
+
applicationId: resolved.info.source === "application" ? resolved.info.ref : undefined,
|
|
99
|
+
runWorkflow: (parent, input) => runOnServer({ ...input, context: parent }),
|
|
100
|
+
runScript: async (parent, input) => {
|
|
101
|
+
if (deps.runScript) {
|
|
102
|
+
return deps.runScript(input);
|
|
103
|
+
}
|
|
104
|
+
const { createJsScriptAppRunner } = await import("@nodetool-ai/agents");
|
|
105
|
+
return createJsScriptAppRunner(LOCAL_USER_ID, { context: parent, secretResolver: getSecret })(input);
|
|
106
|
+
} });
|
|
107
|
+
Object.assign(simulateDeps, recording);
|
|
108
|
+
}
|
|
109
|
+
const report = await simulateApp(resolved, options, simulateDeps);
|
|
110
|
+
report.run_ids = [...runIds];
|
|
111
|
+
report.bundleDir = outDir;
|
|
112
|
+
await writeFile(join(outDir, "report.json"), JSON.stringify(report, null, 2), "utf8");
|
|
113
|
+
await writeFile(join(outDir, "report.md"), renderAppReportMarkdown(report), "utf8");
|
|
114
|
+
return report;
|
|
115
|
+
}
|
|
116
|
+
//# sourceMappingURL=harness.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"harness.js","sourceRoot":"","sources":["../../src/app-debug/harness.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,kBAAkB,CAAC;AACpD,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAC1C,OAAO,EACL,uBAAuB,EACvB,WAAW,EAKZ,MAAM,kCAAkC,CAAC;AAI1C,OAAO,EAAE,gBAAgB,EAAsB,MAAM,iBAAiB,CAAC;AACvE,OAAO,EAAE,aAAa,EAAE,MAAM,gBAAgB,CAAC;AAO/C,OAAO,EAAE,mBAAmB,EAAE,MAAM,kCAAkC,CAAC;AAEvE,oEAAoE;AACpE,MAAM,aAAa,GAAG,GAAG,CAAC;AAwB1B,SAAS,aAAa,CAAC,GAAW;IAChC,MAAM,IAAI,GACR,GAAG;SACA,OAAO,CAAC,kBAAkB,EAAE,GAAG,CAAC;SAChC,OAAO,CAAC,UAAU,EAAE,EAAE,CAAC;SACvB,KAAK,CAAC,CAAC,EAAE,EAAE,CAAC,IAAI,UAAU,CAAC;IAChC,MAAM,KAAK,GAAG,IAAI,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC,CAAC;IAC7D,OAAO,OAAO,CAAC,sBAAsB,IAAI,IAAI,KAAK,EAAE,CAAC,CAAC;AACxD,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,WAAW,CAC/B,GAAW,EACX,OAAwB,EACxB,IAAkB;IAElB,MAAM,UAAU,GAA2C;QACzD,UAAU,EAAE,IAAI,CAAC,UAAU;KAC5B,CAAC;IACF,IAAI,IAAI,CAAC,eAAe,EAAE,CAAC;QACzB,UA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IAAI,EAAE,CAAC,CAAC,EAC/B,MAAM,CACP,CAAC;IACF,MAAM,SAAS,CACb,IAAI,CAAC,MAAM,EAAE,WAAW,CAAC,EACzB,uBAAuB,CAAC,MAAM,CAAC,EAC/B,MAAM,CACP,CAAC;IAEF,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The CLI's app-debug surface: target resolution plus the bundle-writing
|
|
3
|
+
* harness, over the simulator in `@nodetool-ai/execution/app-debug`. The
|
|
4
|
+
* simulator's exports are re-exported here so importers keep one entry point.
|
|
5
|
+
*/
|
|
6
|
+
export { runAppDebug, defaultInteractions } from "./harness.js";
|
|
7
|
+
export type { AppDebugDeps } from "./harness.js";
|
|
8
|
+
export { resolveAppTarget } from "./app-target.js";
|
|
9
|
+
export type { AppApplicationRecord, AppTargetDeps, AppWorkflowRecord } from "./app-target.js";
|
|
10
|
+
export { bindingScopeFor, documentOperations, effectiveTimeoutMs, extractAppIO, HeadlessAppRuntime, InMemoryResourceProvider, operationSpec, parseAppDocument, parseAppSpec, renderAppReportMarkdown, seedResourceHint, simulateApp, validateApp } from "@nodetool-ai/execution/app-debug";
|
|
11
|
+
export type * from "@nodetool-ai/execution/app-debug";
|
|
12
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/app-debug/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAChE,YAAY,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AACjD,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AACnD,YAAY,EACV,oBAAoB,EACpB,aAAa,EACb,iBAAiB,EAClB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,eAAe,EACf,kBAAkB,EAClB,kBAAkB,EAClB,YAAY,EACZ,kBAAkB,EAClB,wBAAwB,EACxB,aAAa,EACb,gBAAgB,EAChB,YAAY,EACZ,uBAAuB,EACvB,gBAAgB,EAChB,WAAW,EACX,WAAW,EACZ,MAAM,kCAAkC,CAAC;AAC1C,mBAAmB,kCAAkC,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The CLI's app-debug surface: target resolution plus the bundle-writing
|
|
3
|
+
* harness, over the simulator in `@nodetool-ai/execution/app-debug`. The
|
|
4
|
+
* simulator's exports are re-exported here so importers keep one entry point.
|
|
5
|
+
*/
|
|
6
|
+
export { runAppDebug, defaultInteractions } from "./harness.js";
|
|
7
|
+
export { resolveAppTarget } from "./app-target.js";
|
|
8
|
+
export { bindingScopeFor, documentOperations, effectiveTimeoutMs, extractAppIO, HeadlessAppRuntime, InMemoryResourceProvider, operationSpec, parseAppDocument, parseAppSpec, renderAppReportMarkdown, seedResourceHint, simulateApp, validateApp } from "@nodetool-ai/execution/app-debug";
|
|
9
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/app-debug/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EAAE,WAAW,EAAE,mBAAmB,EAAE,MAAM,cAAc,CAAC;AAEhE,OAAO,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAMnD,OAAO,EACL,eAAe,EACf,kBAAkB,EAClB,kBAAkB,EAClB,YAAY,EACZ,kBAAkB,EAClB,wBAAwB,EACxB,aAAa,EACb,gBAAgB,EAChB,YAAY,EACZ,uBAAuB,EACvB,gBAAgB,EAChB,WAAW,EACX,WAAW,EACZ,MAAM,kCAAkC,CAAC"}
|
package/dist/app.d.ts
CHANGED
|
@@ -1,50 +1,40 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
toolArgs?: Record<string, unknown>;
|
|
23
|
-
rendered?: string;
|
|
1
|
+
import React from "react";
|
|
2
|
+
import type { EventEmitter } from "node:events";
|
|
3
|
+
import { type PermissionMode } from "@nodetool-ai/agents";
|
|
4
|
+
import { ChatSessionStore } from "./chat-sessions.js";
|
|
5
|
+
export type { ChatMessage } from "./terminal-screen.js";
|
|
6
|
+
export interface AppProps {
|
|
7
|
+
readonly mouseEvents?: EventEmitter;
|
|
8
|
+
readonly initialProvider: string;
|
|
9
|
+
readonly initialModel: string;
|
|
10
|
+
/** `--tools`: narrows the belt to these names. Unset offers the full belt. */
|
|
11
|
+
readonly enabledTools?: string[];
|
|
12
|
+
readonly workspaceDir: string;
|
|
13
|
+
readonly wsUrl?: string;
|
|
14
|
+
readonly registry?: import("@nodetool-ai/node-sdk").NodeRegistry;
|
|
15
|
+
readonly agentProviders?: Record<string, import("@nodetool-ai/runtime").BaseProvider>;
|
|
16
|
+
readonly costCap?: string;
|
|
17
|
+
readonly timeout?: string;
|
|
18
|
+
readonly permissionMode?: PermissionMode;
|
|
19
|
+
readonly enableReadOnlySearch?: boolean;
|
|
20
|
+
readonly resume?: string | boolean;
|
|
21
|
+
readonly sessionStore?: ChatSessionStore;
|
|
24
22
|
}
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
* the curated `nodetool.*` core nodes plus a `find_model` tool.
|
|
43
|
-
*/
|
|
44
|
-
registry?: import("@nodetool-ai/node-sdk").NodeRegistry;
|
|
45
|
-
/** Configured BaseProvider instances by id for `find_model`. */
|
|
46
|
-
agentProviders?: Record<string, import("@nodetool-ai/runtime").BaseProvider>;
|
|
47
|
-
}
|
|
48
|
-
export declare function App({ initialProvider, initialModel, initialAgentMode, initialAgentPlanner, enabledTools, workspaceDir, wsUrl, extraTools, registry, agentProviders, }: AppProps): import("react/jsx-runtime").JSX.Element;
|
|
49
|
-
export {};
|
|
23
|
+
export declare const CHAT_COMMANDS: {
|
|
24
|
+
readonly "/help": "Commands and keyboard shortcuts";
|
|
25
|
+
readonly "/new": "Start a new conversation";
|
|
26
|
+
readonly "/clear": "Clear the screen, keep conversation context";
|
|
27
|
+
readonly "/compact": "Summarize retained context";
|
|
28
|
+
readonly "/model": "Choose a model";
|
|
29
|
+
readonly "/agent": "Inspect sub-agent threads: /agent [id|main]";
|
|
30
|
+
readonly "/mode": "Permissions: default, auto, plan";
|
|
31
|
+
readonly "/sessions": "Browse saved conversations";
|
|
32
|
+
readonly "/resume": "Resume a session: /resume <id>";
|
|
33
|
+
readonly "/export": "Save transcript: /export <path.md>";
|
|
34
|
+
readonly "/tools": "Show available tools";
|
|
35
|
+
readonly "/details": "Toggle tool arguments, code and diffs";
|
|
36
|
+
readonly "/exit": "Save and quit";
|
|
37
|
+
readonly "/quit": "Save and quit";
|
|
38
|
+
};
|
|
39
|
+
export declare function App({ initialProvider, initialModel, enabledTools, workspaceDir, wsUrl, registry, agentProviders, costCap, timeout, permissionMode, enableReadOnlySearch, resume, sessionStore, mouseEvents }: AppProps): React.ReactElement;
|
|
50
40
|
//# sourceMappingURL=app.d.ts.map
|
package/dist/app.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../src/app.tsx"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"app.d.ts","sourceRoot":"","sources":["../src/app.tsx"],"names":[],"mappings":"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