@a5c-ai/agent-platform 5.0.1-staging.04ca6ab00d21 → 5.0.1-staging.6ab464ce4307

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 (66) hide show
  1. package/README.md +8 -13
  2. package/dist/daemon/index.d.ts +2 -0
  3. package/dist/daemon/index.d.ts.map +1 -1
  4. package/dist/daemon/index.js +5 -1
  5. package/dist/harness/index.d.ts +8 -0
  6. package/dist/harness/index.d.ts.map +1 -1
  7. package/dist/harness/index.js +26 -1
  8. package/dist/index.d.ts +0 -1
  9. package/dist/index.d.ts.map +1 -1
  10. package/dist/index.js +0 -1
  11. package/dist/seams/contract.d.ts +5 -5
  12. package/dist/seams/contract.d.ts.map +1 -1
  13. package/dist/seams/contract.js +3 -5
  14. package/dist/seams/contract.test.js +4 -7
  15. package/package.json +13 -17
  16. package/dist/cli/amuxEventsFormatter.d.ts +0 -26
  17. package/dist/cli/amuxEventsFormatter.d.ts.map +0 -1
  18. package/dist/cli/amuxEventsFormatter.js +0 -86
  19. package/dist/cli/args/argFlags.d.ts +0 -6
  20. package/dist/cli/args/argFlags.d.ts.map +0 -1
  21. package/dist/cli/args/argFlags.js +0 -72
  22. package/dist/cli/args/argPositionals.d.ts +0 -3
  23. package/dist/cli/args/argPositionals.d.ts.map +0 -1
  24. package/dist/cli/args/argPositionals.js +0 -18
  25. package/dist/cli/args/index.d.ts +0 -4
  26. package/dist/cli/args/index.d.ts.map +0 -1
  27. package/dist/cli/args/index.js +0 -75
  28. package/dist/cli/args/types.d.ts +0 -13
  29. package/dist/cli/args/types.d.ts.map +0 -1
  30. package/dist/cli/args/types.js +0 -2
  31. package/dist/cli/commands/daemon.d.ts +0 -31
  32. package/dist/cli/commands/daemon.d.ts.map +0 -1
  33. package/dist/cli/commands/daemon.js +0 -156
  34. package/dist/cli/commands/harness/createRun.d.ts +0 -3
  35. package/dist/cli/commands/harness/createRun.d.ts.map +0 -1
  36. package/dist/cli/commands/harness/createRun.js +0 -8
  37. package/dist/cli/commands/harness/resumeRun.d.ts +0 -20
  38. package/dist/cli/commands/harness/resumeRun.d.ts.map +0 -1
  39. package/dist/cli/commands/harness/resumeRun.js +0 -341
  40. package/dist/cli/commands/jsonlInteractive.d.ts +0 -35
  41. package/dist/cli/commands/jsonlInteractive.d.ts.map +0 -1
  42. package/dist/cli/commands/jsonlInteractive.js +0 -302
  43. package/dist/cli/commands/mcpServe.d.ts +0 -18
  44. package/dist/cli/commands/mcpServe.d.ts.map +0 -1
  45. package/dist/cli/commands/mcpServe.js +0 -59
  46. package/dist/cli/commands/session/history.d.ts +0 -14
  47. package/dist/cli/commands/session/history.d.ts.map +0 -1
  48. package/dist/cli/commands/session/history.js +0 -100
  49. package/dist/cli/commands/tui.d.ts +0 -23
  50. package/dist/cli/commands/tui.d.ts.map +0 -1
  51. package/dist/cli/commands/tui.js +0 -183
  52. package/dist/cli/dispatch.d.ts +0 -4
  53. package/dist/cli/dispatch.d.ts.map +0 -1
  54. package/dist/cli/dispatch.js +0 -332
  55. package/dist/cli/main.d.ts +0 -7
  56. package/dist/cli/main.d.ts.map +0 -1
  57. package/dist/cli/main.js +0 -41
  58. package/dist/cli/program.d.ts +0 -7
  59. package/dist/cli/program.d.ts.map +0 -1
  60. package/dist/cli/program.js +0 -8
  61. package/dist/cli/ui.d.ts +0 -9
  62. package/dist/cli/ui.d.ts.map +0 -1
  63. package/dist/cli/ui.js +0 -125
  64. package/dist/prompts/commandTemplates.d.ts +0 -3
  65. package/dist/prompts/commandTemplates.d.ts.map +0 -1
  66. package/dist/prompts/commandTemplates.js +0 -238
package/README.md CHANGED
@@ -1,34 +1,29 @@
1
1
  # @a5c-ai/agent-platform
2
2
 
3
- Agent Platform layer — harness integration, governance, CLI hosting, interaction, storage.
3
+ Agent Platform layer — harness integration, governance, interaction, storage.
4
4
 
5
5
  <!-- docs-status:start -->
6
6
  > Status: Public advanced/runtime package.
7
7
  > Canonical docs home: [Package and Plugin Docs Map](../../docs/package-and-plugin-map.md).
8
- > This README is the canonical runtime CLI contract for operator-facing `agent-platform` workflows.
8
+ > This README is the canonical runtime/platform API contract. The product CLI implementation lives in `@a5c-ai/omni`.
9
9
  <!-- docs-status:end -->
10
10
 
11
11
  ## Installation
12
12
 
13
13
  ```bash
14
- npm install -g @a5c-ai/agent-platform
14
+ npm install @a5c-ai/agent-platform
15
15
  ```
16
16
 
17
17
  ## Usage
18
18
 
19
- This package provides the `agent-platform` command. Use it for runtime orchestration.
19
+ Use this package as the reusable platform API layer. Install `@a5c-ai/omni` for the product CLI.
20
20
 
21
- ```bash
22
- agent-platform --help
23
- agent-platform call --harness claude-code --prompt "implement feature X" --workspace .
24
- babysitter session:init --session-id demo --state-dir .a5c --run-id run-123
25
- agent-platform start-server --transport stdio
26
- agent-platform discover --json
27
- agent-platform invoke claude-code --prompt "implement feature X" --workspace .
28
- agent-platform tui --workspace .
21
+ ```ts
22
+ import { discoverHarnesses, invokeHarness } from "@a5c-ai/agent-platform/harness";
23
+ import { apiRunStatus } from "@a5c-ai/agent-platform/api";
29
24
  ```
30
25
 
31
- Use the main `babysitter` CLI for harness installation and session-state commands:
26
+ Use `@a5c-ai/omni` for the product CLI and the main `babysitter` CLI for harness installation and session-state commands:
32
27
 
33
28
  ```bash
34
29
  babysitter harness:install claude-code
@@ -4,4 +4,6 @@
4
4
  * through this barrel file.
5
5
  */
6
6
  export { startDaemon, stopDaemon, getDaemonStatus, loadDaemonConfig, writeDaemonConfig, createFileWatcher, createWebhookListener, createTimerScheduler, runDaemonLoop, readDaemonLoopStatus, appendDaemonLog, readDaemonLog, type DaemonConfig, type DaemonStartOptions, type DaemonStartOutput, type DaemonStopOptions, type DaemonStopOutput, type DaemonStatusOptions, type DaemonStatusOutput, type DaemonMetadata, type TriggerConfig, type TriggerEvent, type FileTriggerEvent, type AutomationTriggerEvent, type FileTriggerConfig, type FileWatcherHandle, type WebhookListenerOptions, type WebhookListenerHandle, type TriggerCallback, type TimerSchedulerHandle, type DaemonLoopOptions, type DaemonLoopStatus, type DaemonLogEntry, } from "@a5c-ai/agent-runtime/daemon";
7
+ export { executeAutomationTrigger } from "./automationExecutor";
8
+ export { isAutomationTriggerEvent } from "./types";
7
9
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/daemon/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EACL,WAAW,EACX,UAAU,EACV,eAAe,EACf,gBAAgB,EAChB,iBAAiB,EACjB,iBAAiB,EACjB,qBAAqB,EACrB,oBAAoB,EACpB,aAAa,EACb,oBAAoB,EACpB,eAAe,EACf,aAAa,EACb,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACxB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,YAAY,EACjB,KAAK,gBAAgB,EACrB,KAAK,sBAAsB,EAC3B,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,eAAe,EACpB,KAAK,oBAAoB,EACzB,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,cAAc,GACpB,MAAM,8BAA8B,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/daemon/index.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AACH,OAAO,EACL,WAAW,EACX,UAAU,EACV,eAAe,EACf,gBAAgB,EAChB,iBAAiB,EACjB,iBAAiB,EACjB,qBAAqB,EACrB,oBAAoB,EACpB,aAAa,EACb,oBAAoB,EACpB,eAAe,EACf,aAAa,EACb,KAAK,YAAY,EACjB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,mBAAmB,EACxB,KAAK,kBAAkB,EACvB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,YAAY,EACjB,KAAK,gBAAgB,EACrB,KAAK,sBAAsB,EAC3B,KAAK,iBAAiB,EACtB,KAAK,iBAAiB,EACtB,KAAK,sBAAsB,EAC3B,KAAK,qBAAqB,EAC1B,KAAK,eAAe,EACpB,KAAK,oBAAoB,EACzB,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,cAAc,GACpB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EAAE,wBAAwB,EAAE,MAAM,sBAAsB,CAAC;AAChE,OAAO,EAAE,wBAAwB,EAAE,MAAM,SAAS,CAAC"}
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.readDaemonLog = exports.appendDaemonLog = exports.readDaemonLoopStatus = exports.runDaemonLoop = exports.createTimerScheduler = exports.createWebhookListener = exports.createFileWatcher = exports.writeDaemonConfig = exports.loadDaemonConfig = exports.getDaemonStatus = exports.stopDaemon = exports.startDaemon = void 0;
3
+ exports.isAutomationTriggerEvent = exports.executeAutomationTrigger = exports.readDaemonLog = exports.appendDaemonLog = exports.readDaemonLoopStatus = exports.runDaemonLoop = exports.createTimerScheduler = exports.createWebhookListener = exports.createFileWatcher = exports.writeDaemonConfig = exports.loadDaemonConfig = exports.getDaemonStatus = exports.stopDaemon = exports.startDaemon = void 0;
4
4
  /**
5
5
  * Re-export shim — canonical implementation lives in @a5c-ai/agent-runtime.
6
6
  * Internal agent-platform consumers continue to import via relative paths
@@ -19,3 +19,7 @@ Object.defineProperty(exports, "runDaemonLoop", { enumerable: true, get: functio
19
19
  Object.defineProperty(exports, "readDaemonLoopStatus", { enumerable: true, get: function () { return daemon_1.readDaemonLoopStatus; } });
20
20
  Object.defineProperty(exports, "appendDaemonLog", { enumerable: true, get: function () { return daemon_1.appendDaemonLog; } });
21
21
  Object.defineProperty(exports, "readDaemonLog", { enumerable: true, get: function () { return daemon_1.readDaemonLog; } });
22
+ var automationExecutor_1 = require("./automationExecutor");
23
+ Object.defineProperty(exports, "executeAutomationTrigger", { enumerable: true, get: function () { return automationExecutor_1.executeAutomationTrigger; } });
24
+ var types_1 = require("./types");
25
+ Object.defineProperty(exports, "isAutomationTriggerEvent", { enumerable: true, get: function () { return types_1.isAutomationTriggerEvent; } });
@@ -7,4 +7,12 @@ export { buildLaunchSpec } from "./invoker/launch";
7
7
  export { createAgentCoreSession, type AgentCoreEventListener } from "@a5c-ai/agent-core";
8
8
  export type { AgentCoreSessionHandle } from "@a5c-ai/agent-core";
9
9
  export * as amux from "./amux";
10
+ export { handleHarnessCreateRun, handleSessionCreate, runOrchestrationPhase, selectHarness, } from "./internal/createRun";
11
+ export type { HarnessCreateRunArgs, SessionCreateArgs, } from "./internal/createRun";
12
+ export type { OutputMode, ToolResultShape, } from "./internal/createRun/utils";
13
+ export { BOLD, DIM, MAGENTA, RED, RESET, formatToolResult, writeVerboseBlock, writeVerboseLine, } from "./internal/createRun/utils";
14
+ export { assessRun, discoverRuns } from "./internal/createRun/resumeState";
15
+ export { normalizeBuiltInHarnessName } from "./builtInHarness";
16
+ export { invokeViaAgentMux, type AmuxBridgeOptions, type AmuxBridgeResult, type AmuxEventCallback, type AmuxClient, type AmuxRunHandle, type AmuxAgentEvent, type AmuxInteractionChannel, } from "./amux";
17
+ export { HARNESS_TO_AMUX_ADAPTER, mapHarnessToAmuxAdapter, hasAmuxAdapter, } from "./amux";
10
18
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/harness/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,cAAc,EACd,kBAAkB,EAClB,iBAAiB,EACjB,eAAe,EACf,sBAAsB,EACtB,mBAAmB,EACnB,oBAAoB,EACpB,mBAAmB,EACnB,qBAAqB,EACrB,oBAAoB,EACpB,uBAAuB,EACvB,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,qBAAqB,EACrB,sBAAsB,GACvB,MAAM,SAAS,CAAC;AAEjB,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAC5C,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,iBAAiB,EACjB,eAAe,EACf,aAAa,EACb,gBAAgB,EAChB,sBAAsB,EACtB,UAAU,EACV,UAAU,EACV,YAAY,GACb,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,8BAA8B,EAC9B,+BAA+B,EAC/B,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,kBAAkB,EAClB,aAAa,EACb,mBAAmB,EACnB,iBAAiB,EACjB,kBAAkB,GACnB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,aAAa,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAC7E,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,EAAE,sBAAsB,EAAE,KAAK,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AACzF,YAAY,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AACjE,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/harness/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,cAAc,EACd,kBAAkB,EAClB,iBAAiB,EACjB,eAAe,EACf,sBAAsB,EACtB,mBAAmB,EACnB,oBAAoB,EACpB,mBAAmB,EACnB,qBAAqB,EACrB,oBAAoB,EACpB,uBAAuB,EACvB,qBAAqB,EACrB,qBAAqB,EACrB,uBAAuB,EACvB,qBAAqB,EACrB,sBAAsB,GACvB,MAAM,SAAS,CAAC;AAEjB,OAAO,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAC5C,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,iBAAiB,EACjB,eAAe,EACf,aAAa,EACb,gBAAgB,EAChB,sBAAsB,EACtB,UAAU,EACV,UAAU,EACV,YAAY,GACb,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,8BAA8B,EAC9B,+BAA+B,EAC/B,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,kBAAkB,EAClB,aAAa,EACb,mBAAmB,EACnB,iBAAiB,EACjB,kBAAkB,GACnB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,aAAa,EAAE,gBAAgB,EAAE,eAAe,EAAE,MAAM,WAAW,CAAC;AAC7E,OAAO,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAC;AACnD,OAAO,EAAE,sBAAsB,EAAE,KAAK,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AACzF,YAAY,EAAE,sBAAsB,EAAE,MAAM,oBAAoB,CAAC;AACjE,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,mBAAmB,EACnB,qBAAqB,EACrB,aAAa,GACd,MAAM,sBAAsB,CAAC;AAC9B,YAAY,EACV,oBAAoB,EACpB,iBAAiB,GAClB,MAAM,sBAAsB,CAAC;AAC9B,YAAY,EACV,UAAU,EACV,eAAe,GAChB,MAAM,4BAA4B,CAAC;AACpC,OAAO,EACL,IAAI,EACJ,GAAG,EACH,OAAO,EACP,GAAG,EACH,KAAK,EACL,gBAAgB,EAChB,iBAAiB,EACjB,gBAAgB,GACjB,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,kCAAkC,CAAC;AAC3E,OAAO,EAAE,2BAA2B,EAAE,MAAM,kBAAkB,CAAC;AAC/D,OAAO,EACL,iBAAiB,EACjB,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,iBAAiB,EACtB,KAAK,UAAU,EACf,KAAK,aAAa,EAClB,KAAK,cAAc,EACnB,KAAK,sBAAsB,GAC5B,MAAM,QAAQ,CAAC;AAEhB,OAAO,EACL,uBAAuB,EACvB,uBAAuB,EACvB,cAAc,GACf,MAAM,QAAQ,CAAC"}
@@ -33,7 +33,7 @@ var __importStar = (this && this.__importStar) || (function () {
33
33
  };
34
34
  })();
35
35
  Object.defineProperty(exports, "__esModule", { value: true });
36
- exports.amux = exports.createAgentCoreSession = exports.buildLaunchSpec = exports.HARNESS_CLI_MAP = exports.buildHarnessArgs = exports.invokeHarness = exports.parseSearchResults = exports.filterByRelevance = exports.extractTextFromHtml = exports.stripHtmlTags = exports.AGENTIC_TOOL_NAMES = exports.disposeAgentCoreToolDefinitions = exports.createAgentCoreToolDefinitions = exports.resetAdapter = exports.setAdapter = exports.getAdapter = exports.listSupportedHarnesses = exports.getAdapterByName = exports.detectAdapter = exports.KNOWN_HARNESSES = exports.checkCliAvailable = exports.detectCallerHarness = exports.discoverHarnesses = exports.HarnessCapability = void 0;
36
+ exports.hasAmuxAdapter = exports.mapHarnessToAmuxAdapter = exports.HARNESS_TO_AMUX_ADAPTER = exports.invokeViaAgentMux = exports.normalizeBuiltInHarnessName = exports.discoverRuns = exports.assessRun = exports.writeVerboseLine = exports.writeVerboseBlock = exports.formatToolResult = exports.RESET = exports.RED = exports.MAGENTA = exports.DIM = exports.BOLD = exports.selectHarness = exports.runOrchestrationPhase = exports.handleSessionCreate = exports.handleHarnessCreateRun = exports.amux = exports.createAgentCoreSession = exports.buildLaunchSpec = exports.HARNESS_CLI_MAP = exports.buildHarnessArgs = exports.invokeHarness = exports.parseSearchResults = exports.filterByRelevance = exports.extractTextFromHtml = exports.stripHtmlTags = exports.AGENTIC_TOOL_NAMES = exports.disposeAgentCoreToolDefinitions = exports.createAgentCoreToolDefinitions = exports.resetAdapter = exports.setAdapter = exports.getAdapter = exports.listSupportedHarnesses = exports.getAdapterByName = exports.detectAdapter = exports.KNOWN_HARNESSES = exports.checkCliAvailable = exports.detectCallerHarness = exports.discoverHarnesses = exports.HarnessCapability = void 0;
37
37
  var types_1 = require("./types");
38
38
  Object.defineProperty(exports, "HarnessCapability", { enumerable: true, get: function () { return types_1.HarnessCapability; } });
39
39
  var babysitter_sdk_1 = require("@a5c-ai/babysitter-sdk");
@@ -64,3 +64,28 @@ Object.defineProperty(exports, "buildLaunchSpec", { enumerable: true, get: funct
64
64
  var agent_core_2 = require("@a5c-ai/agent-core");
65
65
  Object.defineProperty(exports, "createAgentCoreSession", { enumerable: true, get: function () { return agent_core_2.createAgentCoreSession; } });
66
66
  exports.amux = __importStar(require("./amux"));
67
+ var createRun_1 = require("./internal/createRun");
68
+ Object.defineProperty(exports, "handleHarnessCreateRun", { enumerable: true, get: function () { return createRun_1.handleHarnessCreateRun; } });
69
+ Object.defineProperty(exports, "handleSessionCreate", { enumerable: true, get: function () { return createRun_1.handleSessionCreate; } });
70
+ Object.defineProperty(exports, "runOrchestrationPhase", { enumerable: true, get: function () { return createRun_1.runOrchestrationPhase; } });
71
+ Object.defineProperty(exports, "selectHarness", { enumerable: true, get: function () { return createRun_1.selectHarness; } });
72
+ var utils_1 = require("./internal/createRun/utils");
73
+ Object.defineProperty(exports, "BOLD", { enumerable: true, get: function () { return utils_1.BOLD; } });
74
+ Object.defineProperty(exports, "DIM", { enumerable: true, get: function () { return utils_1.DIM; } });
75
+ Object.defineProperty(exports, "MAGENTA", { enumerable: true, get: function () { return utils_1.MAGENTA; } });
76
+ Object.defineProperty(exports, "RED", { enumerable: true, get: function () { return utils_1.RED; } });
77
+ Object.defineProperty(exports, "RESET", { enumerable: true, get: function () { return utils_1.RESET; } });
78
+ Object.defineProperty(exports, "formatToolResult", { enumerable: true, get: function () { return utils_1.formatToolResult; } });
79
+ Object.defineProperty(exports, "writeVerboseBlock", { enumerable: true, get: function () { return utils_1.writeVerboseBlock; } });
80
+ Object.defineProperty(exports, "writeVerboseLine", { enumerable: true, get: function () { return utils_1.writeVerboseLine; } });
81
+ var resumeState_1 = require("./internal/createRun/resumeState");
82
+ Object.defineProperty(exports, "assessRun", { enumerable: true, get: function () { return resumeState_1.assessRun; } });
83
+ Object.defineProperty(exports, "discoverRuns", { enumerable: true, get: function () { return resumeState_1.discoverRuns; } });
84
+ var builtInHarness_1 = require("./builtInHarness");
85
+ Object.defineProperty(exports, "normalizeBuiltInHarnessName", { enumerable: true, get: function () { return builtInHarness_1.normalizeBuiltInHarnessName; } });
86
+ var amux_1 = require("./amux");
87
+ Object.defineProperty(exports, "invokeViaAgentMux", { enumerable: true, get: function () { return amux_1.invokeViaAgentMux; } });
88
+ var amux_2 = require("./amux");
89
+ Object.defineProperty(exports, "HARNESS_TO_AMUX_ADAPTER", { enumerable: true, get: function () { return amux_2.HARNESS_TO_AMUX_ADAPTER; } });
90
+ Object.defineProperty(exports, "mapHarnessToAmuxAdapter", { enumerable: true, get: function () { return amux_2.mapHarnessToAmuxAdapter; } });
91
+ Object.defineProperty(exports, "hasAmuxAdapter", { enumerable: true, get: function () { return amux_2.hasAmuxAdapter; } });
package/dist/index.d.ts CHANGED
@@ -1,4 +1,3 @@
1
- export * from "./cli/main";
2
1
  export * from "./harness";
3
2
  export * from "./runtime";
4
3
  export * from "./api";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAY,CAAC;AAC3B,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAC1B,cAAc,OAAO,CAAC;AACtB,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,UAAU,MAAM,cAAc,CAAC;AAC3C,cAAc,iBAAiB,CAAC;AAChC,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC;AACrC,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC;AACrC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,KAAK,SAAS,MAAM,aAAa,CAAC;AACzC,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAC;AAC1B,cAAc,WAAW,CAAC;AAC1B,cAAc,OAAO,CAAC;AACtB,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,IAAI,MAAM,QAAQ,CAAC;AAC/B,OAAO,KAAK,UAAU,MAAM,cAAc,CAAC;AAC3C,cAAc,iBAAiB,CAAC;AAChC,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC;AACrC,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC;AACrC,OAAO,KAAK,KAAK,MAAM,SAAS,CAAC;AACjC,OAAO,KAAK,SAAS,MAAM,aAAa,CAAC;AACzC,OAAO,KAAK,MAAM,MAAM,UAAU,CAAC;AACnC,OAAO,KAAK,OAAO,MAAM,WAAW,CAAC"}
package/dist/index.js CHANGED
@@ -37,7 +37,6 @@ var __importStar = (this && this.__importStar) || (function () {
37
37
  })();
38
38
  Object.defineProperty(exports, "__esModule", { value: true });
39
39
  exports.plugins = exports.skills = exports.processes = exports.tasks = exports.storage = exports.session = exports.governance = exports.cost = exports.anycli = void 0;
40
- __exportStar(require("./cli/main"), exports);
41
40
  __exportStar(require("./harness"), exports);
42
41
  __exportStar(require("./runtime"), exports);
43
42
  __exportStar(require("./api"), exports);
@@ -14,7 +14,7 @@ export declare const babysitterAgentSeamContracts: readonly [{
14
14
  readonly owner: "runtime-core";
15
15
  readonly visibility: "public";
16
16
  readonly responsibilities: ["Own orchestration/runtime helpers that remain aligned with the SDK replay model.", "Own persisted run state, session continuity, task artifacts, and prompt/compression helpers used by runtime flows.", "Provide the default leaf seam to validate before proposing any extraction of runtime internals."];
17
- readonly directories: ["runtime", "session", "storage", "tasks", "prompts", "compression"];
17
+ readonly directories: ["runtime", "session", "storage", "tasks", "compression"];
18
18
  readonly packageExports: ["./runtime", "./session", "./storage", "./tasks"];
19
19
  readonly validationCommands: ["npm run build --workspace=@a5c-ai/agent-platform", "npm run test --workspace=@a5c-ai/agent-platform"];
20
20
  }, {
@@ -31,15 +31,15 @@ export declare const babysitterAgentSeamContracts: readonly [{
31
31
  readonly visibility: "public";
32
32
  readonly responsibilities: ["Own harness invocation, agent-core integration, MCP transport/client glue, and API-facing orchestration adapters.", "Keep external integration surfaces grouped under one review boundary until a narrower runtime seam proves real."];
33
33
  readonly directories: ["harness", "mcp", "api", "anycli"];
34
- readonly packageExports: ["./harness", "./api", "./anycli"];
34
+ readonly packageExports: ["./harness", "./api", "./mcp/transport", "./anycli"];
35
35
  readonly validationCommands: ["npm run build --workspace=@a5c-ai/agent-platform", "npm run test --workspace=@a5c-ai/agent-platform"];
36
36
  }, {
37
37
  readonly id: "operator-surfaces";
38
38
  readonly owner: "runtime-operations";
39
39
  readonly visibility: "public";
40
- readonly responsibilities: ["Own operator-facing surfaces such as the CLI, daemon lifecycle, interaction UX, cost reporting, and observability helpers.", "Contain operational changes so user-facing workflows can be validated without reopening every runtime concern."];
41
- readonly directories: ["cli", "daemon", "interaction", "observability", "cost"];
42
- readonly packageExports: ["./cli", "./daemon", "./interaction", "./observability", "./cost"];
40
+ readonly responsibilities: ["Own operator-facing platform helpers such as daemon lifecycle, interaction UX, cost reporting, and observability helpers.", "Contain operational support changes so user-facing workflows can be validated without reopening every runtime concern."];
41
+ readonly directories: ["daemon", "interaction", "observability", "cost"];
42
+ readonly packageExports: ["./daemon", "./interaction", "./observability", "./cost"];
43
43
  readonly validationCommands: ["npm run build --workspace=@a5c-ai/agent-platform", "npm run test --workspace=@a5c-ai/agent-platform"];
44
44
  }, {
45
45
  readonly id: "platform-capabilities";
@@ -1 +1 @@
1
- {"version":3,"file":"contract.d.ts","sourceRoot":"","sources":["../../src/seams/contract.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,6BAA6B,GAAG,QAAQ,GAAG,UAAU,CAAC;AAElE,MAAM,WAAW,2BAA2B;IAC1C,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,6BAA6B,CAAC;IAC1C,gBAAgB,EAAE,MAAM,EAAE,CAAC;IAC3B,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,cAAc,EAAE,MAAM,EAAE,CAAC;IACzB,kBAAkB,EAAE,MAAM,EAAE,CAAC;CAC9B;AAED,eAAO,MAAM,yCAAyC,kHAG5C,CAAC;AAEX,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA4HkB,CAAC;AAE5D,wBAAgB,kCAAkC,IAAI,MAAM,EAAE,CAE7D;AAED,wBAAgB,gCAAgC,IAAI,MAAM,EAAE,CAE3D"}
1
+ {"version":3,"file":"contract.d.ts","sourceRoot":"","sources":["../../src/seams/contract.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,6BAA6B,GAAG,QAAQ,GAAG,UAAU,CAAC;AAElE,MAAM,WAAW,2BAA2B;IAC1C,EAAE,EAAE,MAAM,CAAC;IACX,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,6BAA6B,CAAC;IAC1C,gBAAgB,EAAE,MAAM,EAAE,CAAC;IAC3B,WAAW,EAAE,MAAM,EAAE,CAAC;IACtB,cAAc,EAAE,MAAM,EAAE,CAAC;IACzB,kBAAkB,EAAE,MAAM,EAAE,CAAC;CAC9B;AAED,eAAO,MAAM,yCAAyC,kHAG5C,CAAC;AAEX,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA0HkB,CAAC;AAE5D,wBAAgB,kCAAkC,IAAI,MAAM,EAAE,CAE7D;AAED,wBAAgB,gCAAgC,IAAI,MAAM,EAAE,CAE3D"}
@@ -22,7 +22,6 @@ exports.babysitterAgentSeamContracts = [
22
22
  "session",
23
23
  "storage",
24
24
  "tasks",
25
- "prompts",
26
25
  "compression",
27
26
  ],
28
27
  packageExports: [
@@ -67,6 +66,7 @@ exports.babysitterAgentSeamContracts = [
67
66
  packageExports: [
68
67
  "./harness",
69
68
  "./api",
69
+ "./mcp/transport",
70
70
  "./anycli",
71
71
  ],
72
72
  validationCommands: [...exports.BABYSITTER_AGENT_SEAM_VALIDATION_COMMANDS],
@@ -76,18 +76,16 @@ exports.babysitterAgentSeamContracts = [
76
76
  owner: "runtime-operations",
77
77
  visibility: "public",
78
78
  responsibilities: [
79
- "Own operator-facing surfaces such as the CLI, daemon lifecycle, interaction UX, cost reporting, and observability helpers.",
80
- "Contain operational changes so user-facing workflows can be validated without reopening every runtime concern.",
79
+ "Own operator-facing platform helpers such as daemon lifecycle, interaction UX, cost reporting, and observability helpers.",
80
+ "Contain operational support changes so user-facing workflows can be validated without reopening every runtime concern.",
81
81
  ],
82
82
  directories: [
83
- "cli",
84
83
  "daemon",
85
84
  "interaction",
86
85
  "observability",
87
86
  "cost",
88
87
  ],
89
88
  packageExports: [
90
- "./cli",
91
89
  "./daemon",
92
90
  "./interaction",
93
91
  "./observability",
@@ -27,12 +27,12 @@ const seamAdrPath = node_path_1.default.resolve(packageRoot, "..", "..", "docs",
27
27
  ".",
28
28
  "./anycli",
29
29
  "./api",
30
- "./cli",
31
30
  "./cost",
32
31
  "./daemon",
33
32
  "./governance",
34
33
  "./harness",
35
34
  "./interaction",
35
+ "./mcp/transport",
36
36
  "./observability",
37
37
  "./package.json",
38
38
  "./plugins",
@@ -47,12 +47,12 @@ const seamAdrPath = node_path_1.default.resolve(packageRoot, "..", "..", "docs",
47
47
  (0, vitest_1.expect)((0, contract_1.listBabysitterAgentPublicExports)().sort()).toEqual([
48
48
  "./anycli",
49
49
  "./api",
50
- "./cli",
51
50
  "./cost",
52
51
  "./daemon",
53
52
  "./governance",
54
53
  "./harness",
55
54
  "./interaction",
55
+ "./mcp/transport",
56
56
  "./observability",
57
57
  "./plugins",
58
58
  "./processes",
@@ -64,12 +64,9 @@ const seamAdrPath = node_path_1.default.resolve(packageRoot, "..", "..", "docs",
64
64
  "./tasks",
65
65
  ]);
66
66
  });
67
- (0, vitest_1.test)("publishes both runtime CLI entrypoint aliases", async () => {
67
+ (0, vitest_1.test)("does not publish product CLI entrypoint aliases", async () => {
68
68
  const packageJson = JSON.parse(await node_fs_1.promises.readFile(node_path_1.default.join(packageRoot, "package.json"), "utf8"));
69
- (0, vitest_1.expect)(packageJson.bin).toEqual({
70
- "agent-platform": "dist/cli/main.js",
71
- "babysitter-harness": "dist/cli/main.js",
72
- });
69
+ (0, vitest_1.expect)(packageJson.bin).toBeUndefined();
73
70
  });
74
71
  (0, vitest_1.test)("keeps the validation gate stable for every seam", () => {
75
72
  (0, vitest_1.expect)(contract_1.BABYSITTER_AGENT_SEAM_VALIDATION_COMMANDS).toEqual([
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@a5c-ai/agent-platform",
3
- "version": "5.0.1-staging.04ca6ab00d21",
4
- "description": "Agent Platform layer — harness integration, governance, CLI hosting, interaction, storage",
3
+ "version": "5.0.1-staging.6ab464ce4307",
4
+ "description": "Agent Platform layer — harness integration, governance, interaction, storage",
5
5
  "license": "MIT",
6
6
  "type": "commonjs",
7
7
  "main": "dist/index.js",
@@ -22,11 +22,6 @@
22
22
  "require": "./dist/api/index.js",
23
23
  "default": "./dist/api/index.js"
24
24
  },
25
- "./cli": {
26
- "types": "./dist/cli/main.d.ts",
27
- "require": "./dist/cli/main.js",
28
- "default": "./dist/cli/main.js"
29
- },
30
25
  "./cost": {
31
26
  "types": "./dist/cost/index.d.ts",
32
27
  "require": "./dist/cost/index.js",
@@ -97,11 +92,12 @@
97
92
  "require": "./dist/tasks/index.js",
98
93
  "default": "./dist/tasks/index.js"
99
94
  },
100
- "./package.json": "./package.json"
101
- },
102
- "bin": {
103
- "agent-platform": "dist/cli/main.js",
104
- "babysitter-harness": "dist/cli/main.js"
95
+ "./package.json": "./package.json",
96
+ "./mcp/transport": {
97
+ "types": "./dist/mcp/transport/index.d.ts",
98
+ "require": "./dist/mcp/transport/index.js",
99
+ "default": "./dist/mcp/transport/index.js"
100
+ }
105
101
  },
106
102
  "files": [
107
103
  "dist/",
@@ -118,11 +114,11 @@
118
114
  "test:seams": "vitest run --config vitest.config.ts src/seams/contract.test.ts"
119
115
  },
120
116
  "dependencies": {
121
- "@a5c-ai/agent-core": "5.0.1-staging.04ca6ab00d21",
122
- "@a5c-ai/agent-mux": "5.0.1-staging.04ca6ab00d21",
123
- "@a5c-ai/agent-comm-mux": "5.0.1-staging.04ca6ab00d21",
124
- "@a5c-ai/agent-runtime": "5.0.1-staging.04ca6ab00d21",
125
- "@a5c-ai/babysitter-sdk": "5.0.1-staging.04ca6ab00d21",
117
+ "@a5c-ai/agent-core": "5.0.1-staging.6ab464ce4307",
118
+ "@a5c-ai/agent-mux": "5.0.1-staging.6ab464ce4307",
119
+ "@a5c-ai/agent-comm-mux": "5.0.1-staging.6ab464ce4307",
120
+ "@a5c-ai/agent-runtime": "5.0.1-staging.6ab464ce4307",
121
+ "@a5c-ai/babysitter-sdk": "5.0.1-staging.6ab464ce4307",
126
122
  "@agentsh/secure-sandbox": "^0.1.7",
127
123
  "@earendil-works/pi-coding-agent": "^0.74.0",
128
124
  "@modelcontextprotocol/sdk": "^1.12.1",
@@ -1,26 +0,0 @@
1
- /**
2
- * Formats agent-platform invocation results as agent-mux compatible
3
- * JSONL events.
4
- *
5
- * When `--output-format amux-events` is used, the `invoke` command
6
- * outputs one JSON object per line to stdout so agent-mux's babysitter
7
- * adapter can parse our output as a normalised event stream.
8
- *
9
- * @module cli/amuxEventsFormatter
10
- */
11
- import type { HarnessInvokeResult } from "../harness/types";
12
- /**
13
- * Convert a HarnessInvokeResult into an array of JSONL strings
14
- * representing agent-mux compatible events.
15
- *
16
- * Events emitted:
17
- * 1. `session_start` -- marks the beginning of the invocation
18
- * 2. `text_delta` -- the full output text (one event)
19
- * 3. `cost` -- duration metadata
20
- * 4. `session_end` -- marks the end, carries exit code and success flag
21
- *
22
- * If the result contains an error (exitCode !== 0), an `error` event is
23
- * emitted before `session_end`.
24
- */
25
- export declare function formatResultAsAmuxEvents(harness: string, result: HarnessInvokeResult): string[];
26
- //# sourceMappingURL=amuxEventsFormatter.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"amuxEventsFormatter.d.ts","sourceRoot":"","sources":["../../src/cli/amuxEventsFormatter.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAC;AAe5D;;;;;;;;;;;;GAYG;AACH,wBAAgB,wBAAwB,CACtC,OAAO,EAAE,MAAM,EACf,MAAM,EAAE,mBAAmB,GAC1B,MAAM,EAAE,CAiEV"}
@@ -1,86 +0,0 @@
1
- "use strict";
2
- /**
3
- * Formats agent-platform invocation results as agent-mux compatible
4
- * JSONL events.
5
- *
6
- * When `--output-format amux-events` is used, the `invoke` command
7
- * outputs one JSON object per line to stdout so agent-mux's babysitter
8
- * adapter can parse our output as a normalised event stream.
9
- *
10
- * @module cli/amuxEventsFormatter
11
- */
12
- Object.defineProperty(exports, "__esModule", { value: true });
13
- exports.formatResultAsAmuxEvents = formatResultAsAmuxEvents;
14
- const amuxHarnessMap_1 = require("../harness/amux/amuxHarnessMap");
15
- /**
16
- * Convert a HarnessInvokeResult into an array of JSONL strings
17
- * representing agent-mux compatible events.
18
- *
19
- * Events emitted:
20
- * 1. `session_start` -- marks the beginning of the invocation
21
- * 2. `text_delta` -- the full output text (one event)
22
- * 3. `cost` -- duration metadata
23
- * 4. `session_end` -- marks the end, carries exit code and success flag
24
- *
25
- * If the result contains an error (exitCode !== 0), an `error` event is
26
- * emitted before `session_end`.
27
- */
28
- function formatResultAsAmuxEvents(harness, result) {
29
- const agent = (0, amuxHarnessMap_1.hasAmuxAdapter)(harness)
30
- ? (0, amuxHarnessMap_1.mapHarnessToAmuxAdapter)(harness)
31
- : harness;
32
- const runId = `babysitter-${Date.now()}`;
33
- const now = new Date().toISOString();
34
- const lines = [];
35
- const emit = (event) => {
36
- lines.push(JSON.stringify(event));
37
- };
38
- // 1. Session start
39
- emit({
40
- type: "session_start",
41
- runId,
42
- agent,
43
- timestamp: now,
44
- harness,
45
- });
46
- // 2. Full text output as a single text_delta
47
- if (result.output) {
48
- emit({
49
- type: "text_delta",
50
- runId,
51
- agent,
52
- timestamp: now,
53
- text: result.output,
54
- });
55
- }
56
- // 3. Cost / duration
57
- emit({
58
- type: "cost",
59
- runId,
60
- agent,
61
- timestamp: now,
62
- durationMs: result.duration,
63
- });
64
- // 4. Error (if any)
65
- if (!result.success) {
66
- emit({
67
- type: "error",
68
- runId,
69
- agent,
70
- timestamp: now,
71
- exitCode: result.exitCode,
72
- message: result.output,
73
- });
74
- }
75
- // 5. Session end
76
- emit({
77
- type: "session_end",
78
- runId,
79
- agent,
80
- timestamp: now,
81
- exitCode: result.exitCode,
82
- success: result.success,
83
- durationMs: result.duration,
84
- });
85
- return lines;
86
- }
@@ -1,6 +0,0 @@
1
- import type { HarnessParsedArgs } from "./types";
2
- type FlagParser = (parsed: HarnessParsedArgs, args: string[], index: number) => number;
3
- export declare const BOOLEAN_FLAGS: Record<string, (parsed: HarnessParsedArgs) => void>;
4
- export declare const FLAG_PARSERS: Record<string, FlagParser>;
5
- export {};
6
- //# sourceMappingURL=argFlags.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"argFlags.d.ts","sourceRoot":"","sources":["../../../src/cli/args/argFlags.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAEjD,KAAK,UAAU,GAAG,CAAC,MAAM,EAAE,iBAAiB,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,KAAK,EAAE,MAAM,KAAK,MAAM,CAAC;AAcvF,eAAO,MAAM,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,CAAC,MAAM,EAAE,iBAAiB,KAAK,IAAI,CAK7E,CAAC;AAEF,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,UAAU,CAmDnD,CAAC"}
@@ -1,72 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.FLAG_PARSERS = exports.BOOLEAN_FLAGS = void 0;
4
- const babysitter_sdk_1 = require("@a5c-ai/babysitter-sdk");
5
- function expectFlagValue(args, index, flag) {
6
- const value = args[index];
7
- if (!value) {
8
- throw new Error(`${flag} requires a value`);
9
- }
10
- return value;
11
- }
12
- function parseIntegerFlag(raw) {
13
- return parseInt(raw, 10);
14
- }
15
- exports.BOOLEAN_FLAGS = {
16
- ...babysitter_sdk_1.BOOLEAN_FLAGS,
17
- "--mcp": (parsed) => {
18
- parsed.anycliMcp = true;
19
- },
20
- };
21
- exports.FLAG_PARSERS = {
22
- ...babysitter_sdk_1.FLAG_PARSERS,
23
- "--transport": (parsed, args, index) => {
24
- parsed.transport = expectFlagValue(args, index + 1, "--transport");
25
- parsed.anycliTransport = parsed.transport;
26
- return index + 1;
27
- },
28
- "--service": (parsed, args, index) => {
29
- parsed.anycliService = expectFlagValue(args, index + 1, "--service");
30
- return index + 1;
31
- },
32
- "--scope": (parsed, args, index) => {
33
- parsed.anycliScope = expectFlagValue(args, index + 1, "--scope");
34
- return index + 1;
35
- },
36
- "--auth-file": (parsed, args, index) => {
37
- parsed.anycliAuthFile = expectFlagValue(args, index + 1, "--auth-file");
38
- return index + 1;
39
- },
40
- "--port": (parsed, args, index) => {
41
- parsed.port = parseIntegerFlag(expectFlagValue(args, index + 1, "--port"));
42
- return index + 1;
43
- },
44
- "--host": (parsed, args, index) => {
45
- parsed.host = expectFlagValue(args, index + 1, "--host");
46
- return index + 1;
47
- },
48
- "--auth-token": (parsed, args, index) => {
49
- parsed.authToken = expectFlagValue(args, index + 1, "--auth-token");
50
- return index + 1;
51
- },
52
- "--ws-ping-interval": (parsed, args, index) => {
53
- parsed.wsPingInterval = parseIntegerFlag(expectFlagValue(args, index + 1, "--ws-ping-interval"));
54
- return index + 1;
55
- },
56
- "--ws-grace-period": (parsed, args, index) => {
57
- parsed.wsGracePeriod = parseIntegerFlag(expectFlagValue(args, index + 1, "--ws-grace-period"));
58
- return index + 1;
59
- },
60
- "--ws-max-mps": (parsed, args, index) => {
61
- parsed.wsMaxMps = parseIntegerFlag(expectFlagValue(args, index + 1, "--ws-max-mps"));
62
- return index + 1;
63
- },
64
- "--output-format": (parsed, args, index) => {
65
- const value = expectFlagValue(args, index + 1, "--output-format");
66
- if (value !== "json" && value !== "text" && value !== "amux-events") {
67
- throw new Error(`--output-format must be one of: json, text, amux-events (got "${value}")`);
68
- }
69
- parsed.outputFormat = value;
70
- return index + 1;
71
- },
72
- };
@@ -1,3 +0,0 @@
1
- import type { HarnessParsedArgs } from "./types";
2
- export declare function applyPositionalArgs(parsed: HarnessParsedArgs, positionals: string[]): void;
3
- //# sourceMappingURL=argPositionals.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"argPositionals.d.ts","sourceRoot":"","sources":["../../../src/cli/args/argPositionals.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAEjD,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,iBAAiB,EAAE,WAAW,EAAE,MAAM,EAAE,QAgBnF"}
@@ -1,18 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.applyPositionalArgs = applyPositionalArgs;
4
- const babysitter_sdk_1 = require("@a5c-ai/babysitter-sdk");
5
- function applyPositionalArgs(parsed, positionals) {
6
- (0, babysitter_sdk_1.applyPositionalArgs)(parsed, positionals);
7
- if (parsed.command === "anycli") {
8
- if (!parsed.anycliService &&
9
- positionals.length > 0 &&
10
- /^[a-zA-Z0-9-]+$/.test(positionals[0])) {
11
- [parsed.anycliService] = positionals;
12
- positionals = positionals.slice(1);
13
- }
14
- if (positionals.length > 0 && !parsed.prompt) {
15
- parsed.prompt = positionals.join(" ");
16
- }
17
- }
18
- }
@@ -1,4 +0,0 @@
1
- import type { HarnessParsedArgs } from "./types";
2
- export declare function parseHarnessArgs(argv: string[]): HarnessParsedArgs;
3
- export type { HarnessParsedArgs };
4
- //# sourceMappingURL=index.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/cli/args/index.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAwCjD,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,EAAE,GAAG,iBAAiB,CAuClE;AAED,YAAY,EAAE,iBAAiB,EAAE,CAAC"}