agent-relay 4.0.40 → 6.0.0
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/dist/index.cjs +599 -197
- package/dist/packages/sdk/src/provisioner/local-jwks.d.ts +25 -0
- package/dist/packages/sdk/src/provisioner/local-jwks.d.ts.map +1 -0
- package/dist/packages/sdk/src/provisioner/local-jwks.js +70 -0
- package/dist/packages/sdk/src/provisioner/local-jwks.js.map +1 -0
- package/dist/packages/sdk/src/provisioner/token.d.ts +6 -3
- package/dist/packages/sdk/src/provisioner/token.d.ts.map +1 -1
- package/dist/packages/sdk/src/provisioner/token.js +11 -8
- package/dist/packages/sdk/src/provisioner/token.js.map +1 -1
- package/dist/src/cli/commands/on/provision.d.ts +2 -1
- package/dist/src/cli/commands/on/provision.d.ts.map +1 -1
- package/dist/src/cli/commands/on/provision.js +5 -4
- package/dist/src/cli/commands/on/provision.js.map +1 -1
- package/dist/src/cli/commands/on/services.d.ts +1 -0
- package/dist/src/cli/commands/on/services.d.ts.map +1 -1
- package/dist/src/cli/commands/on/services.js +9 -0
- package/dist/src/cli/commands/on/services.js.map +1 -1
- package/dist/src/cli/commands/on/start.d.ts +6 -3
- package/dist/src/cli/commands/on/start.d.ts.map +1 -1
- package/dist/src/cli/commands/on/start.js +310 -297
- package/dist/src/cli/commands/on/start.js.map +1 -1
- package/dist/src/cli/commands/on/token.d.ts +3 -1
- package/dist/src/cli/commands/on/token.d.ts.map +1 -1
- package/dist/src/cli/commands/on/token.js +3 -3
- package/dist/src/cli/commands/on/token.js.map +1 -1
- package/node_modules/@agent-relay/broker-darwin-arm64/README.md +11 -0
- package/node_modules/@agent-relay/broker-darwin-arm64/package.json +17 -0
- package/node_modules/@agent-relay/broker-darwin-x64/README.md +11 -0
- package/node_modules/@agent-relay/broker-darwin-x64/bin/.gitkeep +0 -0
- package/node_modules/@agent-relay/broker-darwin-x64/package.json +17 -0
- package/node_modules/@agent-relay/broker-linux-arm64/README.md +12 -0
- package/node_modules/@agent-relay/broker-linux-arm64/bin/.gitkeep +0 -0
- package/node_modules/@agent-relay/broker-linux-arm64/package.json +17 -0
- package/node_modules/@agent-relay/broker-linux-x64/README.md +12 -0
- package/node_modules/@agent-relay/broker-linux-x64/bin/.gitkeep +0 -0
- package/node_modules/@agent-relay/broker-linux-x64/package.json +17 -0
- package/node_modules/@agent-relay/broker-win32-x64/README.md +11 -0
- package/node_modules/@agent-relay/broker-win32-x64/bin/.gitkeep +0 -0
- package/node_modules/@agent-relay/broker-win32-x64/package.json +17 -0
- package/node_modules/@agent-relay/cloud/package.json +2 -2
- package/node_modules/@agent-relay/config/dist/cli-registry.generated.d.ts +353 -157
- package/node_modules/@agent-relay/config/dist/cli-registry.generated.d.ts.map +1 -1
- package/node_modules/@agent-relay/config/dist/cli-registry.generated.js +356 -160
- package/node_modules/@agent-relay/config/dist/cli-registry.generated.js.map +1 -1
- package/node_modules/@agent-relay/config/package.json +1 -1
- package/node_modules/@agent-relay/hooks/package.json +4 -4
- package/node_modules/@agent-relay/sdk/dist/broker-path.d.ts +18 -7
- package/node_modules/@agent-relay/sdk/dist/broker-path.d.ts.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/broker-path.js +92 -20
- package/node_modules/@agent-relay/sdk/dist/broker-path.js.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/client.d.ts.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/client.js +9 -2
- package/node_modules/@agent-relay/sdk/dist/client.js.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/provisioner/__tests__/audit.test.js +2 -2
- package/node_modules/@agent-relay/sdk/dist/provisioner/__tests__/audit.test.js.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/provisioner/__tests__/token-factory.test.js +29 -17
- package/node_modules/@agent-relay/sdk/dist/provisioner/__tests__/token-factory.test.js.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/provisioner/__tests__/token.test.js +8 -3
- package/node_modules/@agent-relay/sdk/dist/provisioner/__tests__/token.test.js.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/provisioner/index.d.ts +1 -0
- package/node_modules/@agent-relay/sdk/dist/provisioner/index.d.ts.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/provisioner/index.js +5 -2
- package/node_modules/@agent-relay/sdk/dist/provisioner/index.js.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/provisioner/local-jwks.d.ts +25 -0
- package/node_modules/@agent-relay/sdk/dist/provisioner/local-jwks.d.ts.map +1 -0
- package/node_modules/@agent-relay/sdk/dist/provisioner/local-jwks.js +70 -0
- package/node_modules/@agent-relay/sdk/dist/provisioner/local-jwks.js.map +1 -0
- package/node_modules/@agent-relay/sdk/dist/provisioner/token.d.ts +6 -3
- package/node_modules/@agent-relay/sdk/dist/provisioner/token.d.ts.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/provisioner/token.js +11 -8
- package/node_modules/@agent-relay/sdk/dist/provisioner/token.js.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/provisioner/types.d.ts +3 -2
- package/node_modules/@agent-relay/sdk/dist/provisioner/types.d.ts.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/workflows/__tests__/sibling-links.test.d.ts +2 -0
- package/node_modules/@agent-relay/sdk/dist/workflows/__tests__/sibling-links.test.d.ts.map +1 -0
- package/node_modules/@agent-relay/sdk/dist/workflows/__tests__/sibling-links.test.js +166 -0
- package/node_modules/@agent-relay/sdk/dist/workflows/__tests__/sibling-links.test.js.map +1 -0
- package/node_modules/@agent-relay/sdk/dist/workflows/index.d.ts +2 -0
- package/node_modules/@agent-relay/sdk/dist/workflows/index.d.ts.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/workflows/index.js +1 -0
- package/node_modules/@agent-relay/sdk/dist/workflows/index.js.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/workflows/runner.d.ts.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/workflows/runner.js +18 -1
- package/node_modules/@agent-relay/sdk/dist/workflows/runner.js.map +1 -1
- package/node_modules/@agent-relay/sdk/dist/workflows/sibling-links.d.ts +100 -0
- package/node_modules/@agent-relay/sdk/dist/workflows/sibling-links.d.ts.map +1 -0
- package/node_modules/@agent-relay/sdk/dist/workflows/sibling-links.js +205 -0
- package/node_modules/@agent-relay/sdk/dist/workflows/sibling-links.js.map +1 -0
- package/node_modules/@agent-relay/sdk/package.json +10 -3
- package/node_modules/@agent-relay/telemetry/package.json +1 -1
- package/node_modules/@agent-relay/trajectory/package.json +2 -2
- package/node_modules/@agent-relay/user-directory/package.json +2 -2
- package/node_modules/@agent-relay/utils/package.json +2 -2
- package/node_modules/@aws-sdk/core/package.json +5 -5
- package/node_modules/@aws-sdk/credential-provider-env/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-http/package.json +5 -5
- package/node_modules/@aws-sdk/credential-provider-ini/package.json +9 -9
- package/node_modules/@aws-sdk/credential-provider-login/package.json +3 -3
- package/node_modules/@aws-sdk/credential-provider-node/package.json +7 -7
- package/node_modules/@aws-sdk/credential-provider-process/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-sso/package.json +4 -4
- package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +3 -3
- package/node_modules/@aws-sdk/middleware-flexible-checksums/package.json +4 -4
- package/node_modules/@aws-sdk/middleware-sdk-s3/package.json +5 -5
- package/node_modules/@aws-sdk/middleware-user-agent/package.json +4 -4
- package/node_modules/@aws-sdk/nested-clients/package.json +14 -14
- package/node_modules/@aws-sdk/signature-v4-multi-region/package.json +2 -2
- package/node_modules/@aws-sdk/token-providers/package.json +3 -3
- package/node_modules/@aws-sdk/util-user-agent-node/package.json +2 -2
- package/node_modules/@aws-sdk/xml-builder/dist-cjs/xml-parser.js +0 -2
- package/node_modules/@aws-sdk/xml-builder/dist-es/xml-parser.js +0 -2
- package/node_modules/@aws-sdk/xml-builder/package.json +2 -2
- package/node_modules/@nodable/entities/README.md +41 -0
- package/node_modules/@nodable/entities/package.json +54 -0
- package/node_modules/@nodable/entities/src/EntityDecoder.js +543 -0
- package/node_modules/@nodable/entities/src/EntityEncoder.js +194 -0
- package/node_modules/@nodable/entities/src/entities.js +1177 -0
- package/node_modules/@nodable/entities/src/entityTries.js +49 -0
- package/node_modules/@nodable/entities/src/index.d.ts +264 -0
- package/node_modules/@nodable/entities/src/index.js +29 -0
- package/node_modules/@smithy/core/package.json +2 -2
- package/node_modules/@smithy/middleware-endpoint/package.json +3 -3
- package/node_modules/@smithy/middleware-retry/package.json +4 -4
- package/node_modules/@smithy/middleware-serde/package.json +2 -2
- package/node_modules/@smithy/node-http-handler/dist-cjs/index.js +27 -16
- package/node_modules/@smithy/node-http-handler/dist-es/http2/ClientHttp2SessionRef.js +5 -0
- package/node_modules/@smithy/node-http-handler/dist-es/node-http2-connection-manager.js +22 -16
- package/node_modules/@smithy/node-http-handler/dist-types/http2/ClientHttp2SessionRef.d.ts +4 -0
- package/node_modules/@smithy/node-http-handler/dist-types/node-http2-connection-manager.d.ts +2 -4
- package/node_modules/@smithy/node-http-handler/package.json +1 -1
- package/node_modules/@smithy/smithy-client/package.json +4 -4
- package/node_modules/@smithy/util-defaults-mode-browser/package.json +2 -2
- package/node_modules/@smithy/util-defaults-mode-node/package.json +2 -2
- package/node_modules/@smithy/util-retry/dist-cjs/index.js +20 -10
- package/node_modules/@smithy/util-retry/dist-es/StandardRetryStrategy.js +20 -10
- package/node_modules/@smithy/util-retry/dist-types/StandardRetryStrategy.d.ts +12 -4
- package/node_modules/@smithy/util-retry/package.json +1 -1
- package/node_modules/@smithy/util-stream/package.json +2 -2
- package/node_modules/fast-xml-parser/CHANGELOG.md +53 -0
- package/node_modules/fast-xml-parser/README.md +8 -28
- package/node_modules/fast-xml-parser/lib/fxbuilder.min.js +1 -1
- package/node_modules/fast-xml-parser/lib/fxbuilder.min.js.map +1 -1
- package/node_modules/fast-xml-parser/lib/fxp.cjs +1 -1
- package/node_modules/fast-xml-parser/lib/fxp.d.cts +172 -6
- package/node_modules/fast-xml-parser/lib/fxp.min.js +1 -1
- package/node_modules/fast-xml-parser/lib/fxp.min.js.map +1 -1
- package/node_modules/fast-xml-parser/lib/fxparser.min.js +1 -1
- package/node_modules/fast-xml-parser/lib/fxparser.min.js.map +1 -1
- package/node_modules/fast-xml-parser/package.json +5 -4
- package/node_modules/fast-xml-parser/src/fxp.d.ts +162 -3
- package/node_modules/fast-xml-parser/src/xmlparser/DocTypeReader.js +2 -5
- package/node_modules/fast-xml-parser/src/xmlparser/OptionsBuilder.js +15 -11
- package/node_modules/fast-xml-parser/src/xmlparser/OrderedObjParser.js +168 -244
- package/node_modules/fast-xml-parser/src/xmlparser/XMLParser.js +1 -1
- package/package.json +9 -10
- package/packages/cloud/package.json +2 -2
- package/packages/config/dist/cli-registry.generated.d.ts +353 -157
- package/packages/config/dist/cli-registry.generated.d.ts.map +1 -1
- package/packages/config/dist/cli-registry.generated.js +356 -160
- package/packages/config/dist/cli-registry.generated.js.map +1 -1
- package/packages/config/package.json +1 -1
- package/packages/hooks/package.json +4 -4
- package/packages/sdk/dist/broker-path.d.ts +18 -7
- package/packages/sdk/dist/broker-path.d.ts.map +1 -1
- package/packages/sdk/dist/broker-path.js +92 -20
- package/packages/sdk/dist/broker-path.js.map +1 -1
- package/packages/sdk/dist/client.d.ts.map +1 -1
- package/packages/sdk/dist/client.js +9 -2
- package/packages/sdk/dist/client.js.map +1 -1
- package/packages/sdk/dist/provisioner/__tests__/audit.test.js +2 -2
- package/packages/sdk/dist/provisioner/__tests__/audit.test.js.map +1 -1
- package/packages/sdk/dist/provisioner/__tests__/token-factory.test.js +29 -17
- package/packages/sdk/dist/provisioner/__tests__/token-factory.test.js.map +1 -1
- package/packages/sdk/dist/provisioner/__tests__/token.test.js +8 -3
- package/packages/sdk/dist/provisioner/__tests__/token.test.js.map +1 -1
- package/packages/sdk/dist/provisioner/index.d.ts +1 -0
- package/packages/sdk/dist/provisioner/index.d.ts.map +1 -1
- package/packages/sdk/dist/provisioner/index.js +5 -2
- package/packages/sdk/dist/provisioner/index.js.map +1 -1
- package/packages/sdk/dist/provisioner/local-jwks.d.ts +25 -0
- package/packages/sdk/dist/provisioner/local-jwks.d.ts.map +1 -0
- package/packages/sdk/dist/provisioner/local-jwks.js +70 -0
- package/packages/sdk/dist/provisioner/local-jwks.js.map +1 -0
- package/packages/sdk/dist/provisioner/token.d.ts +6 -3
- package/packages/sdk/dist/provisioner/token.d.ts.map +1 -1
- package/packages/sdk/dist/provisioner/token.js +11 -8
- package/packages/sdk/dist/provisioner/token.js.map +1 -1
- package/packages/sdk/dist/provisioner/types.d.ts +3 -2
- package/packages/sdk/dist/provisioner/types.d.ts.map +1 -1
- package/packages/sdk/dist/workflows/__tests__/sibling-links.test.d.ts +2 -0
- package/packages/sdk/dist/workflows/__tests__/sibling-links.test.d.ts.map +1 -0
- package/packages/sdk/dist/workflows/__tests__/sibling-links.test.js +166 -0
- package/packages/sdk/dist/workflows/__tests__/sibling-links.test.js.map +1 -0
- package/packages/sdk/dist/workflows/index.d.ts +2 -0
- package/packages/sdk/dist/workflows/index.d.ts.map +1 -1
- package/packages/sdk/dist/workflows/index.js +1 -0
- package/packages/sdk/dist/workflows/index.js.map +1 -1
- package/packages/sdk/dist/workflows/runner.d.ts.map +1 -1
- package/packages/sdk/dist/workflows/runner.js +18 -1
- package/packages/sdk/dist/workflows/runner.js.map +1 -1
- package/packages/sdk/dist/workflows/sibling-links.d.ts +100 -0
- package/packages/sdk/dist/workflows/sibling-links.d.ts.map +1 -0
- package/packages/sdk/dist/workflows/sibling-links.js +205 -0
- package/packages/sdk/dist/workflows/sibling-links.js.map +1 -0
- package/packages/sdk/package.json +10 -3
- package/packages/telemetry/package.json +1 -1
- package/packages/trajectory/package.json +2 -2
- package/packages/user-directory/package.json +2 -2
- package/packages/utils/package.json +2 -2
- package/scripts/postinstall.js +9 -146
- package/bin/agent-relay-broker-darwin-arm64 +0 -0
- package/bin/agent-relay-broker-darwin-x64 +0 -0
- package/bin/agent-relay-broker-linux-arm64 +0 -0
- package/bin/agent-relay-broker-linux-x64 +0 -0
- package/node_modules/fast-xml-parser/lib/pem.d.cts +0 -148
- package/node_modules/fast-xml-parser/src/pem.d.ts +0 -135
- /package/{bin → node_modules/@agent-relay/broker-darwin-arm64/bin}/.gitkeep +0 -0
package/dist/index.cjs
CHANGED
|
@@ -2237,7 +2237,7 @@ var require_websocket = __commonJS({
|
|
|
2237
2237
|
var http = require("http");
|
|
2238
2238
|
var net = require("net");
|
|
2239
2239
|
var tls = require("tls");
|
|
2240
|
-
var { randomBytes: randomBytes9, createHash:
|
|
2240
|
+
var { randomBytes: randomBytes9, createHash: createHash4 } = require("crypto");
|
|
2241
2241
|
var { Duplex, Readable } = require("stream");
|
|
2242
2242
|
var { URL: URL2 } = require("url");
|
|
2243
2243
|
var PerMessageDeflate2 = require_permessage_deflate();
|
|
@@ -2897,7 +2897,7 @@ var require_websocket = __commonJS({
|
|
|
2897
2897
|
abortHandshake(websocket, socket, "Invalid Upgrade header");
|
|
2898
2898
|
return;
|
|
2899
2899
|
}
|
|
2900
|
-
const digest =
|
|
2900
|
+
const digest = createHash4("sha1").update(key + GUID).digest("base64");
|
|
2901
2901
|
if (res.headers["sec-websocket-accept"] !== digest) {
|
|
2902
2902
|
abortHandshake(websocket, socket, "Invalid Sec-WebSocket-Accept header");
|
|
2903
2903
|
return;
|
|
@@ -3264,7 +3264,7 @@ var require_websocket_server = __commonJS({
|
|
|
3264
3264
|
var EventEmitter6 = require("events");
|
|
3265
3265
|
var http = require("http");
|
|
3266
3266
|
var { Duplex } = require("stream");
|
|
3267
|
-
var { createHash:
|
|
3267
|
+
var { createHash: createHash4 } = require("crypto");
|
|
3268
3268
|
var extension2 = require_extension();
|
|
3269
3269
|
var PerMessageDeflate2 = require_permessage_deflate();
|
|
3270
3270
|
var subprotocol2 = require_subprotocol();
|
|
@@ -3565,7 +3565,7 @@ var require_websocket_server = __commonJS({
|
|
|
3565
3565
|
);
|
|
3566
3566
|
}
|
|
3567
3567
|
if (this._state > RUNNING) return abortHandshake(socket, 503);
|
|
3568
|
-
const digest =
|
|
3568
|
+
const digest = createHash4("sha1").update(key + GUID).digest("base64");
|
|
3569
3569
|
const headers = [
|
|
3570
3570
|
"HTTP/1.1 101 Switching Protocols",
|
|
3571
3571
|
"Upgrade: websocket",
|
|
@@ -18810,11 +18810,11 @@ var init_types = __esm({
|
|
|
18810
18810
|
});
|
|
18811
18811
|
|
|
18812
18812
|
// packages/memory/dist/adapters/inmemory.js
|
|
18813
|
-
var
|
|
18813
|
+
var import_node_crypto14, InMemoryAdapter;
|
|
18814
18814
|
var init_inmemory = __esm({
|
|
18815
18815
|
"packages/memory/dist/adapters/inmemory.js"() {
|
|
18816
18816
|
"use strict";
|
|
18817
|
-
|
|
18817
|
+
import_node_crypto14 = require("node:crypto");
|
|
18818
18818
|
InMemoryAdapter = class {
|
|
18819
18819
|
type = "inmemory";
|
|
18820
18820
|
memories = /* @__PURE__ */ new Map();
|
|
@@ -18829,7 +18829,7 @@ var init_inmemory = __esm({
|
|
|
18829
18829
|
async init() {
|
|
18830
18830
|
}
|
|
18831
18831
|
async add(content, options) {
|
|
18832
|
-
const id = (0,
|
|
18832
|
+
const id = (0, import_node_crypto14.randomUUID)();
|
|
18833
18833
|
const now = Date.now();
|
|
18834
18834
|
const entry = {
|
|
18835
18835
|
id,
|
|
@@ -20203,12 +20203,14 @@ __export(index_exports, {
|
|
|
20203
20203
|
WorkflowRunner: () => WorkflowRunner,
|
|
20204
20204
|
WorkflowStepLifecycleExecutor: () => StepExecutor,
|
|
20205
20205
|
WorkflowTrajectory: () => WorkflowTrajectory,
|
|
20206
|
+
applySiblingLinks: () => applySiblingLinks,
|
|
20206
20207
|
benchmarkPatterns: () => benchmarkPatterns,
|
|
20207
20208
|
brokerLog: () => brokerLog,
|
|
20208
20209
|
buildBlockReason: () => buildBlockReason,
|
|
20209
20210
|
buildCommand: () => buildCommand,
|
|
20210
20211
|
buildModelSwitchCommand: () => buildModelSwitchCommand,
|
|
20211
20212
|
buildNormalizedProxyEnv: () => buildNormalizedProxyEnv,
|
|
20213
|
+
buildSiblingLinkScript: () => buildSiblingLinkScript,
|
|
20212
20214
|
checkCustom: () => checkCustom,
|
|
20213
20215
|
checkExitCode: () => checkExitCode,
|
|
20214
20216
|
checkFileExists: () => checkFileExists,
|
|
@@ -20543,6 +20545,9 @@ var import_node_child_process = require("node:child_process");
|
|
|
20543
20545
|
var import_node_module = require("node:module");
|
|
20544
20546
|
var import_node_url = require("node:url");
|
|
20545
20547
|
var BROKER_NAME = "agent-relay-broker";
|
|
20548
|
+
function getOptionalDepPackageName(platform2 = process.platform, arch = process.arch) {
|
|
20549
|
+
return `@agent-relay/broker-${platform2}-${arch}`;
|
|
20550
|
+
}
|
|
20546
20551
|
function addUniquePath(paths, candidate) {
|
|
20547
20552
|
if (!candidate || paths.includes(candidate)) {
|
|
20548
20553
|
return;
|
|
@@ -20582,6 +20587,33 @@ function getCurrentModuleReference() {
|
|
|
20582
20587
|
}
|
|
20583
20588
|
return getImportMetaUrl();
|
|
20584
20589
|
}
|
|
20590
|
+
function getResolutionReferences() {
|
|
20591
|
+
const refs = [];
|
|
20592
|
+
addUniquePath(refs, getCurrentModuleReference());
|
|
20593
|
+
if (process.argv[1]) {
|
|
20594
|
+
addUniquePath(refs, process.argv[1]);
|
|
20595
|
+
}
|
|
20596
|
+
addUniquePath(refs, (0, import_node_path.join)(process.cwd(), "package.json"));
|
|
20597
|
+
return refs;
|
|
20598
|
+
}
|
|
20599
|
+
function requireResolveFromRefs(specifier) {
|
|
20600
|
+
for (const ref of getResolutionReferences()) {
|
|
20601
|
+
try {
|
|
20602
|
+
return (0, import_node_module.createRequire)(ref).resolve(specifier);
|
|
20603
|
+
} catch {
|
|
20604
|
+
}
|
|
20605
|
+
}
|
|
20606
|
+
return null;
|
|
20607
|
+
}
|
|
20608
|
+
function getOptionalDepBinaryPath(ext) {
|
|
20609
|
+
const pkgName = getOptionalDepPackageName();
|
|
20610
|
+
const binaryFile = `${BROKER_NAME}${ext}`;
|
|
20611
|
+
const pkgJsonPath = requireResolveFromRefs(`${pkgName}/package.json`);
|
|
20612
|
+
if (!pkgJsonPath)
|
|
20613
|
+
return null;
|
|
20614
|
+
const binPath = (0, import_node_path.join)((0, import_node_path.dirname)(pkgJsonPath), "bin", binaryFile);
|
|
20615
|
+
return (0, import_node_fs.existsSync)(binPath) ? binPath : null;
|
|
20616
|
+
}
|
|
20585
20617
|
function getSdkBinDirs() {
|
|
20586
20618
|
const binDirs = [];
|
|
20587
20619
|
const currentModuleDir = getCurrentModuleDir();
|
|
@@ -20669,6 +20701,10 @@ function getBrokerBinaryPath() {
|
|
|
20669
20701
|
return developmentPath;
|
|
20670
20702
|
}
|
|
20671
20703
|
}
|
|
20704
|
+
const optionalDepBinary = getOptionalDepBinaryPath(ext);
|
|
20705
|
+
if (optionalDepBinary) {
|
|
20706
|
+
return optionalDepBinary;
|
|
20707
|
+
}
|
|
20672
20708
|
for (const binDir of binDirs) {
|
|
20673
20709
|
const exactPath = (0, import_node_path.join)(binDir, `${BROKER_NAME}${ext}`);
|
|
20674
20710
|
if ((0, import_node_fs.existsSync)(exactPath)) {
|
|
@@ -20709,6 +20745,10 @@ function getBrokerBinaryPath() {
|
|
|
20709
20745
|
}
|
|
20710
20746
|
return null;
|
|
20711
20747
|
}
|
|
20748
|
+
function formatBrokerNotFoundError() {
|
|
20749
|
+
const pkgName = getOptionalDepPackageName();
|
|
20750
|
+
return `@agent-relay/sdk couldn't find an agent-relay-broker binary for ${process.platform}-${process.arch}. The optional dependency ${pkgName} is expected to be installed alongside @agent-relay/sdk. Try reinstalling with --include=optional, or set BROKER_BINARY_PATH to point at a broker binary you've downloaded manually.`;
|
|
20751
|
+
}
|
|
20712
20752
|
|
|
20713
20753
|
// packages/sdk/dist/client.js
|
|
20714
20754
|
function isHeadlessProvider(value) {
|
|
@@ -20803,7 +20843,14 @@ var AgentRelayClient = class _AgentRelayClient {
|
|
|
20803
20843
|
* 6. Starts event stream + lease renewal
|
|
20804
20844
|
*/
|
|
20805
20845
|
static async spawn(options) {
|
|
20806
|
-
|
|
20846
|
+
let binaryPath = options?.binaryPath;
|
|
20847
|
+
if (!binaryPath) {
|
|
20848
|
+
const resolved = getBrokerBinaryPath();
|
|
20849
|
+
if (!resolved) {
|
|
20850
|
+
throw new Error(formatBrokerNotFoundError());
|
|
20851
|
+
}
|
|
20852
|
+
binaryPath = resolved;
|
|
20853
|
+
}
|
|
20807
20854
|
const cwd = options?.cwd ?? process.cwd();
|
|
20808
20855
|
const brokerName = options?.brokerName ?? (import_node_path2.default.basename(cwd) || "project");
|
|
20809
20856
|
const channels = options?.channels ?? ["general"];
|
|
@@ -26708,10 +26755,10 @@ var jsonSchemas = {
|
|
|
26708
26755
|
var CLIVersions = {
|
|
26709
26756
|
/** Claude Code v2.1.72 */
|
|
26710
26757
|
CLAUDE: "2.1.72",
|
|
26711
|
-
/** Codex CLI v0.
|
|
26712
|
-
CODEX: "0.
|
|
26713
|
-
/** Gemini CLI v0.
|
|
26714
|
-
GEMINI: "0.
|
|
26758
|
+
/** Codex CLI v0.124.0 */
|
|
26759
|
+
CODEX: "0.124.0",
|
|
26760
|
+
/** Gemini CLI v0.39.1 */
|
|
26761
|
+
GEMINI: "0.39.1",
|
|
26715
26762
|
/** Cursor v2026.02.27-e7d2ef6 */
|
|
26716
26763
|
CURSOR: "2026.02.27-e7d2ef6",
|
|
26717
26764
|
/** Droid v0.1.0 */
|
|
@@ -26742,7 +26789,7 @@ var ClaudeModels = {
|
|
|
26742
26789
|
HAIKU: "haiku"
|
|
26743
26790
|
};
|
|
26744
26791
|
var CodexModels = {
|
|
26745
|
-
/** GPT-5.4 —
|
|
26792
|
+
/** GPT-5.4 — Frontier model for complex coding, research, and real-world work. (default) */
|
|
26746
26793
|
GPT_5_4: "gpt-5.4",
|
|
26747
26794
|
/** GPT-5.3 Codex — Frontier agentic coding model */
|
|
26748
26795
|
GPT_5_3_CODEX: "gpt-5.3-codex",
|
|
@@ -26770,94 +26817,192 @@ var GeminiModels = {
|
|
|
26770
26817
|
GEMINI_2_5_FLASH_LITE: "gemini-2.5-flash-lite"
|
|
26771
26818
|
};
|
|
26772
26819
|
var CursorModels = {
|
|
26773
|
-
/**
|
|
26774
|
-
|
|
26775
|
-
/**
|
|
26776
|
-
|
|
26777
|
-
/** Claude 4.5 Opus */
|
|
26778
|
-
OPUS_4_5: "opus-4.5",
|
|
26779
|
-
/** Claude 4.5 Opus (Thinking) */
|
|
26780
|
-
OPUS_4_5_THINKING: "opus-4.5-thinking",
|
|
26781
|
-
/** Claude 4.6 Sonnet */
|
|
26782
|
-
SONNET_4_6: "sonnet-4.6",
|
|
26783
|
-
/** Claude 4.6 Sonnet (Thinking) */
|
|
26784
|
-
SONNET_4_6_THINKING: "sonnet-4.6-thinking",
|
|
26785
|
-
/** Claude 4.5 Sonnet */
|
|
26786
|
-
SONNET_4_5: "sonnet-4.5",
|
|
26787
|
-
/** Claude 4.5 Sonnet (Thinking) */
|
|
26788
|
-
SONNET_4_5_THINKING: "sonnet-4.5-thinking",
|
|
26820
|
+
/** Composer 2 Fast (default) */
|
|
26821
|
+
COMPOSER_2_FAST: "composer-2-fast",
|
|
26822
|
+
/** Composer 2 */
|
|
26823
|
+
COMPOSER_2: "composer-2",
|
|
26789
26824
|
/** Composer 1.5 */
|
|
26790
26825
|
COMPOSER_1_5: "composer-1.5",
|
|
26791
|
-
/**
|
|
26792
|
-
|
|
26793
|
-
/**
|
|
26794
|
-
|
|
26795
|
-
/**
|
|
26796
|
-
|
|
26797
|
-
/**
|
|
26826
|
+
/** Codex 5.3 Low */
|
|
26827
|
+
GPT_5_3_CODEX_LOW: "gpt-5.3-codex-low",
|
|
26828
|
+
/** Codex 5.3 Low Fast */
|
|
26829
|
+
GPT_5_3_CODEX_LOW_FAST: "gpt-5.3-codex-low-fast",
|
|
26830
|
+
/** Codex 5.3 */
|
|
26831
|
+
GPT_5_3_CODEX: "gpt-5.3-codex",
|
|
26832
|
+
/** Codex 5.3 Fast */
|
|
26833
|
+
GPT_5_3_CODEX_FAST: "gpt-5.3-codex-fast",
|
|
26834
|
+
/** Codex 5.3 High */
|
|
26835
|
+
GPT_5_3_CODEX_HIGH: "gpt-5.3-codex-high",
|
|
26836
|
+
/** Codex 5.3 High Fast */
|
|
26837
|
+
GPT_5_3_CODEX_HIGH_FAST: "gpt-5.3-codex-high-fast",
|
|
26838
|
+
/** Codex 5.3 Extra High */
|
|
26839
|
+
GPT_5_3_CODEX_XHIGH: "gpt-5.3-codex-xhigh",
|
|
26840
|
+
/** Codex 5.3 Extra High Fast */
|
|
26841
|
+
GPT_5_3_CODEX_XHIGH_FAST: "gpt-5.3-codex-xhigh-fast",
|
|
26842
|
+
/** GPT-5.2 */
|
|
26843
|
+
GPT_5_2: "gpt-5.2",
|
|
26844
|
+
/** Codex 5.3 Spark Low */
|
|
26845
|
+
GPT_5_3_CODEX_SPARK_PREVIEW_LOW: "gpt-5.3-codex-spark-preview-low",
|
|
26846
|
+
/** Codex 5.3 Spark */
|
|
26847
|
+
GPT_5_3_CODEX_SPARK_PREVIEW: "gpt-5.3-codex-spark-preview",
|
|
26848
|
+
/** Codex 5.3 Spark High */
|
|
26849
|
+
GPT_5_3_CODEX_SPARK_PREVIEW_HIGH: "gpt-5.3-codex-spark-preview-high",
|
|
26850
|
+
/** Codex 5.3 Spark Extra High */
|
|
26851
|
+
GPT_5_3_CODEX_SPARK_PREVIEW_XHIGH: "gpt-5.3-codex-spark-preview-xhigh",
|
|
26852
|
+
/** Codex 5.2 Low */
|
|
26853
|
+
GPT_5_2_CODEX_LOW: "gpt-5.2-codex-low",
|
|
26854
|
+
/** Codex 5.2 Low Fast */
|
|
26855
|
+
GPT_5_2_CODEX_LOW_FAST: "gpt-5.2-codex-low-fast",
|
|
26856
|
+
/** Codex 5.2 */
|
|
26857
|
+
GPT_5_2_CODEX: "gpt-5.2-codex",
|
|
26858
|
+
/** Codex 5.2 Fast */
|
|
26859
|
+
GPT_5_2_CODEX_FAST: "gpt-5.2-codex-fast",
|
|
26860
|
+
/** Codex 5.2 High */
|
|
26861
|
+
GPT_5_2_CODEX_HIGH: "gpt-5.2-codex-high",
|
|
26862
|
+
/** Codex 5.2 High Fast */
|
|
26863
|
+
GPT_5_2_CODEX_HIGH_FAST: "gpt-5.2-codex-high-fast",
|
|
26864
|
+
/** Codex 5.2 Extra High */
|
|
26865
|
+
GPT_5_2_CODEX_XHIGH: "gpt-5.2-codex-xhigh",
|
|
26866
|
+
/** Codex 5.2 Extra High Fast */
|
|
26867
|
+
GPT_5_2_CODEX_XHIGH_FAST: "gpt-5.2-codex-xhigh-fast",
|
|
26868
|
+
/** Codex 5.1 Max Low */
|
|
26869
|
+
GPT_5_1_CODEX_MAX_LOW: "gpt-5.1-codex-max-low",
|
|
26870
|
+
/** Codex 5.1 Max Low Fast */
|
|
26871
|
+
GPT_5_1_CODEX_MAX_LOW_FAST: "gpt-5.1-codex-max-low-fast",
|
|
26872
|
+
/** Codex 5.1 Max */
|
|
26873
|
+
GPT_5_1_CODEX_MAX_MEDIUM: "gpt-5.1-codex-max-medium",
|
|
26874
|
+
/** Codex 5.1 Max Medium Fast */
|
|
26875
|
+
GPT_5_1_CODEX_MAX_MEDIUM_FAST: "gpt-5.1-codex-max-medium-fast",
|
|
26876
|
+
/** Codex 5.1 Max High */
|
|
26877
|
+
GPT_5_1_CODEX_MAX_HIGH: "gpt-5.1-codex-max-high",
|
|
26878
|
+
/** Codex 5.1 Max High Fast */
|
|
26879
|
+
GPT_5_1_CODEX_MAX_HIGH_FAST: "gpt-5.1-codex-max-high-fast",
|
|
26880
|
+
/** Codex 5.1 Max Extra High */
|
|
26881
|
+
GPT_5_1_CODEX_MAX_XHIGH: "gpt-5.1-codex-max-xhigh",
|
|
26882
|
+
/** Codex 5.1 Max Extra High Fast */
|
|
26883
|
+
GPT_5_1_CODEX_MAX_XHIGH_FAST: "gpt-5.1-codex-max-xhigh-fast",
|
|
26884
|
+
/** Opus 4.7 1M High Thinking */
|
|
26885
|
+
CLAUDE_OPUS_4_7_THINKING_HIGH: "claude-opus-4-7-thinking-high",
|
|
26886
|
+
/** GPT-5.4 1M High */
|
|
26798
26887
|
GPT_5_4_HIGH: "gpt-5.4-high",
|
|
26799
26888
|
/** GPT-5.4 High Fast */
|
|
26800
26889
|
GPT_5_4_HIGH_FAST: "gpt-5.4-high-fast",
|
|
26801
|
-
/** GPT-5.4 */
|
|
26890
|
+
/** GPT-5.4 Extra High Fast */
|
|
26891
|
+
GPT_5_4_XHIGH_FAST: "gpt-5.4-xhigh-fast",
|
|
26892
|
+
/** Opus 4.6 1M Thinking Fast */
|
|
26893
|
+
CLAUDE_4_6_OPUS_HIGH_THINKING_FAST: "claude-4.6-opus-high-thinking-fast",
|
|
26894
|
+
/** Sonnet 4.6 1M */
|
|
26895
|
+
CLAUDE_4_6_SONNET_MEDIUM: "claude-4.6-sonnet-medium",
|
|
26896
|
+
/** Sonnet 4.6 1M Thinking */
|
|
26897
|
+
CLAUDE_4_6_SONNET_MEDIUM_THINKING: "claude-4.6-sonnet-medium-thinking",
|
|
26898
|
+
/** Opus 4.7 1M Low */
|
|
26899
|
+
CLAUDE_OPUS_4_7_LOW: "claude-opus-4-7-low",
|
|
26900
|
+
/** Opus 4.7 1M Medium */
|
|
26901
|
+
CLAUDE_OPUS_4_7_MEDIUM: "claude-opus-4-7-medium",
|
|
26902
|
+
/** Opus 4.7 1M High */
|
|
26903
|
+
CLAUDE_OPUS_4_7_HIGH: "claude-opus-4-7-high",
|
|
26904
|
+
/** Opus 4.7 1M */
|
|
26905
|
+
CLAUDE_OPUS_4_7_XHIGH: "claude-opus-4-7-xhigh",
|
|
26906
|
+
/** Opus 4.7 1M Max */
|
|
26907
|
+
CLAUDE_OPUS_4_7_MAX: "claude-opus-4-7-max",
|
|
26908
|
+
/** Opus 4.7 1M Low Thinking */
|
|
26909
|
+
CLAUDE_OPUS_4_7_THINKING_LOW: "claude-opus-4-7-thinking-low",
|
|
26910
|
+
/** Opus 4.7 1M Medium Thinking */
|
|
26911
|
+
CLAUDE_OPUS_4_7_THINKING_MEDIUM: "claude-opus-4-7-thinking-medium",
|
|
26912
|
+
/** Opus 4.7 1M Thinking */
|
|
26913
|
+
CLAUDE_OPUS_4_7_THINKING_XHIGH: "claude-opus-4-7-thinking-xhigh",
|
|
26914
|
+
/** Opus 4.7 1M Max Thinking */
|
|
26915
|
+
CLAUDE_OPUS_4_7_THINKING_MAX: "claude-opus-4-7-thinking-max",
|
|
26916
|
+
/** GPT-5.4 1M Low */
|
|
26917
|
+
GPT_5_4_LOW: "gpt-5.4-low",
|
|
26918
|
+
/** GPT-5.4 1M */
|
|
26802
26919
|
GPT_5_4_MEDIUM: "gpt-5.4-medium",
|
|
26803
26920
|
/** GPT-5.4 Fast */
|
|
26804
26921
|
GPT_5_4_MEDIUM_FAST: "gpt-5.4-medium-fast",
|
|
26805
|
-
/** GPT-5.4
|
|
26806
|
-
|
|
26807
|
-
/**
|
|
26808
|
-
|
|
26809
|
-
/**
|
|
26810
|
-
|
|
26811
|
-
/**
|
|
26812
|
-
|
|
26813
|
-
/**
|
|
26814
|
-
|
|
26815
|
-
/**
|
|
26816
|
-
|
|
26817
|
-
/**
|
|
26818
|
-
|
|
26819
|
-
/**
|
|
26820
|
-
|
|
26821
|
-
/** GPT-5.
|
|
26822
|
-
|
|
26823
|
-
/** GPT-5.
|
|
26824
|
-
|
|
26825
|
-
/** GPT-5.2
|
|
26826
|
-
|
|
26827
|
-
/** GPT-5.2 Codex Extra High Fast */
|
|
26828
|
-
GPT_5_2_CODEX_XHIGH_FAST: "gpt-5.2-codex-xhigh-fast",
|
|
26829
|
-
/** GPT-5.2 Codex High */
|
|
26830
|
-
GPT_5_2_CODEX_HIGH: "gpt-5.2-codex-high",
|
|
26831
|
-
/** GPT-5.2 Codex High Fast */
|
|
26832
|
-
GPT_5_2_CODEX_HIGH_FAST: "gpt-5.2-codex-high-fast",
|
|
26833
|
-
/** GPT-5.2 Codex */
|
|
26834
|
-
GPT_5_2_CODEX: "gpt-5.2-codex",
|
|
26835
|
-
/** GPT-5.2 Codex Fast */
|
|
26836
|
-
GPT_5_2_CODEX_FAST: "gpt-5.2-codex-fast",
|
|
26837
|
-
/** GPT-5.2 Codex Low */
|
|
26838
|
-
GPT_5_2_CODEX_LOW: "gpt-5.2-codex-low",
|
|
26839
|
-
/** GPT-5.2 Codex Low Fast */
|
|
26840
|
-
GPT_5_2_CODEX_LOW_FAST: "gpt-5.2-codex-low-fast",
|
|
26841
|
-
/** GPT-5.2 */
|
|
26842
|
-
GPT_5_2: "gpt-5.2",
|
|
26922
|
+
/** GPT-5.4 1M Extra High */
|
|
26923
|
+
GPT_5_4_XHIGH: "gpt-5.4-xhigh",
|
|
26924
|
+
/** Opus 4.6 1M */
|
|
26925
|
+
CLAUDE_4_6_OPUS_HIGH: "claude-4.6-opus-high",
|
|
26926
|
+
/** Opus 4.6 1M Max */
|
|
26927
|
+
CLAUDE_4_6_OPUS_MAX: "claude-4.6-opus-max",
|
|
26928
|
+
/** Opus 4.6 1M Thinking */
|
|
26929
|
+
CLAUDE_4_6_OPUS_HIGH_THINKING: "claude-4.6-opus-high-thinking",
|
|
26930
|
+
/** Opus 4.6 1M Max Thinking */
|
|
26931
|
+
CLAUDE_4_6_OPUS_MAX_THINKING: "claude-4.6-opus-max-thinking",
|
|
26932
|
+
/** Opus 4.6 1M Max Thinking Fast */
|
|
26933
|
+
CLAUDE_4_6_OPUS_MAX_THINKING_FAST: "claude-4.6-opus-max-thinking-fast",
|
|
26934
|
+
/** Opus 4.5 */
|
|
26935
|
+
CLAUDE_4_5_OPUS_HIGH: "claude-4.5-opus-high",
|
|
26936
|
+
/** Opus 4.5 Thinking */
|
|
26937
|
+
CLAUDE_4_5_OPUS_HIGH_THINKING: "claude-4.5-opus-high-thinking",
|
|
26938
|
+
/** GPT-5.2 Low */
|
|
26939
|
+
GPT_5_2_LOW: "gpt-5.2-low",
|
|
26940
|
+
/** GPT-5.2 Low Fast */
|
|
26941
|
+
GPT_5_2_LOW_FAST: "gpt-5.2-low-fast",
|
|
26942
|
+
/** GPT-5.2 Fast */
|
|
26943
|
+
GPT_5_2_FAST: "gpt-5.2-fast",
|
|
26843
26944
|
/** GPT-5.2 High */
|
|
26844
26945
|
GPT_5_2_HIGH: "gpt-5.2-high",
|
|
26845
|
-
/** GPT-5.
|
|
26846
|
-
|
|
26847
|
-
/** GPT-5.
|
|
26848
|
-
|
|
26849
|
-
/** GPT-5.
|
|
26850
|
-
|
|
26851
|
-
/** GPT-5.1 High */
|
|
26852
|
-
GPT_5_1_HIGH: "gpt-5.1-high",
|
|
26946
|
+
/** GPT-5.2 High Fast */
|
|
26947
|
+
GPT_5_2_HIGH_FAST: "gpt-5.2-high-fast",
|
|
26948
|
+
/** GPT-5.2 Extra High */
|
|
26949
|
+
GPT_5_2_XHIGH: "gpt-5.2-xhigh",
|
|
26950
|
+
/** GPT-5.2 Extra High Fast */
|
|
26951
|
+
GPT_5_2_XHIGH_FAST: "gpt-5.2-xhigh-fast",
|
|
26853
26952
|
/** Gemini 3.1 Pro */
|
|
26854
26953
|
GEMINI_3_1_PRO: "gemini-3.1-pro",
|
|
26855
|
-
/**
|
|
26856
|
-
|
|
26954
|
+
/** GPT-5.4 Mini None */
|
|
26955
|
+
GPT_5_4_MINI_NONE: "gpt-5.4-mini-none",
|
|
26956
|
+
/** GPT-5.4 Mini Low */
|
|
26957
|
+
GPT_5_4_MINI_LOW: "gpt-5.4-mini-low",
|
|
26958
|
+
/** GPT-5.4 Mini */
|
|
26959
|
+
GPT_5_4_MINI_MEDIUM: "gpt-5.4-mini-medium",
|
|
26960
|
+
/** GPT-5.4 Mini High */
|
|
26961
|
+
GPT_5_4_MINI_HIGH: "gpt-5.4-mini-high",
|
|
26962
|
+
/** GPT-5.4 Mini Extra High */
|
|
26963
|
+
GPT_5_4_MINI_XHIGH: "gpt-5.4-mini-xhigh",
|
|
26964
|
+
/** GPT-5.4 Nano None */
|
|
26965
|
+
GPT_5_4_NANO_NONE: "gpt-5.4-nano-none",
|
|
26966
|
+
/** GPT-5.4 Nano Low */
|
|
26967
|
+
GPT_5_4_NANO_LOW: "gpt-5.4-nano-low",
|
|
26968
|
+
/** GPT-5.4 Nano */
|
|
26969
|
+
GPT_5_4_NANO_MEDIUM: "gpt-5.4-nano-medium",
|
|
26970
|
+
/** GPT-5.4 Nano High */
|
|
26971
|
+
GPT_5_4_NANO_HIGH: "gpt-5.4-nano-high",
|
|
26972
|
+
/** GPT-5.4 Nano Extra High */
|
|
26973
|
+
GPT_5_4_NANO_XHIGH: "gpt-5.4-nano-xhigh",
|
|
26974
|
+
/** Grok 4.20 */
|
|
26975
|
+
GROK_4_20: "grok-4-20",
|
|
26976
|
+
/** Grok 4.20 Thinking */
|
|
26977
|
+
GROK_4_20_THINKING: "grok-4-20-thinking",
|
|
26978
|
+
/** Sonnet 4.5 1M */
|
|
26979
|
+
CLAUDE_4_5_SONNET: "claude-4.5-sonnet",
|
|
26980
|
+
/** Sonnet 4.5 1M Thinking */
|
|
26981
|
+
CLAUDE_4_5_SONNET_THINKING: "claude-4.5-sonnet-thinking",
|
|
26982
|
+
/** GPT-5.1 Low */
|
|
26983
|
+
GPT_5_1_LOW: "gpt-5.1-low",
|
|
26984
|
+
/** GPT-5.1 */
|
|
26985
|
+
GPT_5_1: "gpt-5.1",
|
|
26986
|
+
/** GPT-5.1 High */
|
|
26987
|
+
GPT_5_1_HIGH: "gpt-5.1-high",
|
|
26857
26988
|
/** Gemini 3 Flash */
|
|
26858
26989
|
GEMINI_3_FLASH: "gemini-3-flash",
|
|
26859
|
-
/**
|
|
26860
|
-
|
|
26990
|
+
/** Codex 5.1 Mini Low */
|
|
26991
|
+
GPT_5_1_CODEX_MINI_LOW: "gpt-5.1-codex-mini-low",
|
|
26992
|
+
/** Codex 5.1 Mini */
|
|
26993
|
+
GPT_5_1_CODEX_MINI: "gpt-5.1-codex-mini",
|
|
26994
|
+
/** Codex 5.1 Mini High */
|
|
26995
|
+
GPT_5_1_CODEX_MINI_HIGH: "gpt-5.1-codex-mini-high",
|
|
26996
|
+
/** Sonnet 4 */
|
|
26997
|
+
CLAUDE_4_SONNET: "claude-4-sonnet",
|
|
26998
|
+
/** Sonnet 4 1M */
|
|
26999
|
+
CLAUDE_4_SONNET_1M: "claude-4-sonnet-1m",
|
|
27000
|
+
/** Sonnet 4 Thinking */
|
|
27001
|
+
CLAUDE_4_SONNET_THINKING: "claude-4-sonnet-thinking",
|
|
27002
|
+
/** Sonnet 4 1M Thinking */
|
|
27003
|
+
CLAUDE_4_SONNET_1M_THINKING: "claude-4-sonnet-1m-thinking",
|
|
27004
|
+
/** GPT-5 Mini */
|
|
27005
|
+
GPT_5_MINI: "gpt-5-mini",
|
|
26861
27006
|
/** Kimi K2.5 */
|
|
26862
27007
|
KIMI_K2_5: "kimi-k2.5"
|
|
26863
27008
|
};
|
|
@@ -26981,7 +27126,7 @@ var CLAUDE_MODEL_OPTIONS = [
|
|
|
26981
27126
|
{ value: "haiku", label: "Haiku" }
|
|
26982
27127
|
];
|
|
26983
27128
|
var CODEX_MODEL_OPTIONS = [
|
|
26984
|
-
{ value: "gpt-5.4", label: "GPT-5.4 \u2014
|
|
27129
|
+
{ value: "gpt-5.4", label: "GPT-5.4 \u2014 Frontier model for complex coding, research, and real-world work.", reasoningEfforts: ["low", "medium", "high", "xhigh"], defaultReasoningEffort: "xhigh" },
|
|
26985
27130
|
{ value: "gpt-5.3-codex", label: "GPT-5.3 Codex \u2014 Frontier agentic coding model", reasoningEfforts: ["low", "medium", "high", "xhigh"], defaultReasoningEffort: "xhigh" },
|
|
26986
27131
|
{ value: "gpt-5.3-codex-spark", label: "GPT-5.3 Codex Spark \u2014 Ultra-fast coding model", reasoningEfforts: ["low", "medium", "high", "xhigh"], defaultReasoningEffort: "xhigh" },
|
|
26987
27132
|
{ value: "gpt-5.2-codex", label: "GPT-5.2 Codex \u2014 Frontier agentic coding model", reasoningEfforts: ["low", "medium", "high", "xhigh"], defaultReasoningEffort: "xhigh" },
|
|
@@ -26997,50 +27142,99 @@ var GEMINI_MODEL_OPTIONS = [
|
|
|
26997
27142
|
{ value: "gemini-2.5-flash-lite", label: "Gemini 2.5 Flash Lite" }
|
|
26998
27143
|
];
|
|
26999
27144
|
var CURSOR_MODEL_OPTIONS = [
|
|
27000
|
-
{ value: "
|
|
27001
|
-
{ value: "
|
|
27002
|
-
{ value: "opus-4.5", label: "Claude 4.5 Opus" },
|
|
27003
|
-
{ value: "opus-4.5-thinking", label: "Claude 4.5 Opus (Thinking)" },
|
|
27004
|
-
{ value: "sonnet-4.6", label: "Claude 4.6 Sonnet" },
|
|
27005
|
-
{ value: "sonnet-4.6-thinking", label: "Claude 4.6 Sonnet (Thinking)" },
|
|
27006
|
-
{ value: "sonnet-4.5", label: "Claude 4.5 Sonnet" },
|
|
27007
|
-
{ value: "sonnet-4.5-thinking", label: "Claude 4.5 Sonnet (Thinking)" },
|
|
27145
|
+
{ value: "composer-2-fast", label: "Composer 2 Fast" },
|
|
27146
|
+
{ value: "composer-2", label: "Composer 2" },
|
|
27008
27147
|
{ value: "composer-1.5", label: "Composer 1.5" },
|
|
27009
|
-
{ value: "
|
|
27010
|
-
{ value: "gpt-5.
|
|
27011
|
-
{ value: "gpt-5.
|
|
27012
|
-
{ value: "gpt-5.
|
|
27148
|
+
{ value: "gpt-5.3-codex-low", label: "Codex 5.3 Low" },
|
|
27149
|
+
{ value: "gpt-5.3-codex-low-fast", label: "Codex 5.3 Low Fast" },
|
|
27150
|
+
{ value: "gpt-5.3-codex", label: "Codex 5.3" },
|
|
27151
|
+
{ value: "gpt-5.3-codex-fast", label: "Codex 5.3 Fast" },
|
|
27152
|
+
{ value: "gpt-5.3-codex-high", label: "Codex 5.3 High" },
|
|
27153
|
+
{ value: "gpt-5.3-codex-high-fast", label: "Codex 5.3 High Fast" },
|
|
27154
|
+
{ value: "gpt-5.3-codex-xhigh", label: "Codex 5.3 Extra High" },
|
|
27155
|
+
{ value: "gpt-5.3-codex-xhigh-fast", label: "Codex 5.3 Extra High Fast" },
|
|
27156
|
+
{ value: "gpt-5.2", label: "GPT-5.2" },
|
|
27157
|
+
{ value: "gpt-5.3-codex-spark-preview-low", label: "Codex 5.3 Spark Low" },
|
|
27158
|
+
{ value: "gpt-5.3-codex-spark-preview", label: "Codex 5.3 Spark" },
|
|
27159
|
+
{ value: "gpt-5.3-codex-spark-preview-high", label: "Codex 5.3 Spark High" },
|
|
27160
|
+
{ value: "gpt-5.3-codex-spark-preview-xhigh", label: "Codex 5.3 Spark Extra High" },
|
|
27161
|
+
{ value: "gpt-5.2-codex-low", label: "Codex 5.2 Low" },
|
|
27162
|
+
{ value: "gpt-5.2-codex-low-fast", label: "Codex 5.2 Low Fast" },
|
|
27163
|
+
{ value: "gpt-5.2-codex", label: "Codex 5.2" },
|
|
27164
|
+
{ value: "gpt-5.2-codex-fast", label: "Codex 5.2 Fast" },
|
|
27165
|
+
{ value: "gpt-5.2-codex-high", label: "Codex 5.2 High" },
|
|
27166
|
+
{ value: "gpt-5.2-codex-high-fast", label: "Codex 5.2 High Fast" },
|
|
27167
|
+
{ value: "gpt-5.2-codex-xhigh", label: "Codex 5.2 Extra High" },
|
|
27168
|
+
{ value: "gpt-5.2-codex-xhigh-fast", label: "Codex 5.2 Extra High Fast" },
|
|
27169
|
+
{ value: "gpt-5.1-codex-max-low", label: "Codex 5.1 Max Low" },
|
|
27170
|
+
{ value: "gpt-5.1-codex-max-low-fast", label: "Codex 5.1 Max Low Fast" },
|
|
27171
|
+
{ value: "gpt-5.1-codex-max-medium", label: "Codex 5.1 Max" },
|
|
27172
|
+
{ value: "gpt-5.1-codex-max-medium-fast", label: "Codex 5.1 Max Medium Fast" },
|
|
27173
|
+
{ value: "gpt-5.1-codex-max-high", label: "Codex 5.1 Max High" },
|
|
27174
|
+
{ value: "gpt-5.1-codex-max-high-fast", label: "Codex 5.1 Max High Fast" },
|
|
27175
|
+
{ value: "gpt-5.1-codex-max-xhigh", label: "Codex 5.1 Max Extra High" },
|
|
27176
|
+
{ value: "gpt-5.1-codex-max-xhigh-fast", label: "Codex 5.1 Max Extra High Fast" },
|
|
27177
|
+
{ value: "claude-opus-4-7-thinking-high", label: "Opus 4.7 1M High Thinking" },
|
|
27178
|
+
{ value: "gpt-5.4-high", label: "GPT-5.4 1M High" },
|
|
27013
27179
|
{ value: "gpt-5.4-high-fast", label: "GPT-5.4 High Fast" },
|
|
27014
|
-
{ value: "gpt-5.4-
|
|
27180
|
+
{ value: "gpt-5.4-xhigh-fast", label: "GPT-5.4 Extra High Fast" },
|
|
27181
|
+
{ value: "claude-4.6-opus-high-thinking-fast", label: "Opus 4.6 1M Thinking Fast" },
|
|
27182
|
+
{ value: "claude-4.6-sonnet-medium", label: "Sonnet 4.6 1M" },
|
|
27183
|
+
{ value: "claude-4.6-sonnet-medium-thinking", label: "Sonnet 4.6 1M Thinking" },
|
|
27184
|
+
{ value: "claude-opus-4-7-low", label: "Opus 4.7 1M Low" },
|
|
27185
|
+
{ value: "claude-opus-4-7-medium", label: "Opus 4.7 1M Medium" },
|
|
27186
|
+
{ value: "claude-opus-4-7-high", label: "Opus 4.7 1M High" },
|
|
27187
|
+
{ value: "claude-opus-4-7-xhigh", label: "Opus 4.7 1M" },
|
|
27188
|
+
{ value: "claude-opus-4-7-max", label: "Opus 4.7 1M Max" },
|
|
27189
|
+
{ value: "claude-opus-4-7-thinking-low", label: "Opus 4.7 1M Low Thinking" },
|
|
27190
|
+
{ value: "claude-opus-4-7-thinking-medium", label: "Opus 4.7 1M Medium Thinking" },
|
|
27191
|
+
{ value: "claude-opus-4-7-thinking-xhigh", label: "Opus 4.7 1M Thinking" },
|
|
27192
|
+
{ value: "claude-opus-4-7-thinking-max", label: "Opus 4.7 1M Max Thinking" },
|
|
27193
|
+
{ value: "gpt-5.4-low", label: "GPT-5.4 1M Low" },
|
|
27194
|
+
{ value: "gpt-5.4-medium", label: "GPT-5.4 1M" },
|
|
27015
27195
|
{ value: "gpt-5.4-medium-fast", label: "GPT-5.4 Fast" },
|
|
27016
|
-
{ value: "gpt-5.4-
|
|
27017
|
-
{ value: "
|
|
27018
|
-
{ value: "
|
|
27019
|
-
{ value: "
|
|
27020
|
-
{ value: "
|
|
27021
|
-
{ value: "
|
|
27022
|
-
{ value: "
|
|
27023
|
-
{ value: "
|
|
27024
|
-
{ value: "gpt-5.
|
|
27025
|
-
{ value: "gpt-5.
|
|
27026
|
-
{ value: "gpt-5.2-
|
|
27027
|
-
{ value: "gpt-5.2-codex-xhigh-fast", label: "GPT-5.2 Codex Extra High Fast" },
|
|
27028
|
-
{ value: "gpt-5.2-codex-high", label: "GPT-5.2 Codex High" },
|
|
27029
|
-
{ value: "gpt-5.2-codex-high-fast", label: "GPT-5.2 Codex High Fast" },
|
|
27030
|
-
{ value: "gpt-5.2-codex", label: "GPT-5.2 Codex" },
|
|
27031
|
-
{ value: "gpt-5.2-codex-fast", label: "GPT-5.2 Codex Fast" },
|
|
27032
|
-
{ value: "gpt-5.2-codex-low", label: "GPT-5.2 Codex Low" },
|
|
27033
|
-
{ value: "gpt-5.2-codex-low-fast", label: "GPT-5.2 Codex Low Fast" },
|
|
27034
|
-
{ value: "gpt-5.2", label: "GPT-5.2" },
|
|
27196
|
+
{ value: "gpt-5.4-xhigh", label: "GPT-5.4 1M Extra High" },
|
|
27197
|
+
{ value: "claude-4.6-opus-high", label: "Opus 4.6 1M" },
|
|
27198
|
+
{ value: "claude-4.6-opus-max", label: "Opus 4.6 1M Max" },
|
|
27199
|
+
{ value: "claude-4.6-opus-high-thinking", label: "Opus 4.6 1M Thinking" },
|
|
27200
|
+
{ value: "claude-4.6-opus-max-thinking", label: "Opus 4.6 1M Max Thinking" },
|
|
27201
|
+
{ value: "claude-4.6-opus-max-thinking-fast", label: "Opus 4.6 1M Max Thinking Fast" },
|
|
27202
|
+
{ value: "claude-4.5-opus-high", label: "Opus 4.5" },
|
|
27203
|
+
{ value: "claude-4.5-opus-high-thinking", label: "Opus 4.5 Thinking" },
|
|
27204
|
+
{ value: "gpt-5.2-low", label: "GPT-5.2 Low" },
|
|
27205
|
+
{ value: "gpt-5.2-low-fast", label: "GPT-5.2 Low Fast" },
|
|
27206
|
+
{ value: "gpt-5.2-fast", label: "GPT-5.2 Fast" },
|
|
27035
27207
|
{ value: "gpt-5.2-high", label: "GPT-5.2 High" },
|
|
27036
|
-
{ value: "gpt-5.
|
|
27037
|
-
{ value: "gpt-5.
|
|
27038
|
-
{ value: "gpt-5.
|
|
27039
|
-
{ value: "gpt-5.1-high", label: "GPT-5.1 High" },
|
|
27208
|
+
{ value: "gpt-5.2-high-fast", label: "GPT-5.2 High Fast" },
|
|
27209
|
+
{ value: "gpt-5.2-xhigh", label: "GPT-5.2 Extra High" },
|
|
27210
|
+
{ value: "gpt-5.2-xhigh-fast", label: "GPT-5.2 Extra High Fast" },
|
|
27040
27211
|
{ value: "gemini-3.1-pro", label: "Gemini 3.1 Pro" },
|
|
27041
|
-
{ value: "
|
|
27212
|
+
{ value: "gpt-5.4-mini-none", label: "GPT-5.4 Mini None" },
|
|
27213
|
+
{ value: "gpt-5.4-mini-low", label: "GPT-5.4 Mini Low" },
|
|
27214
|
+
{ value: "gpt-5.4-mini-medium", label: "GPT-5.4 Mini" },
|
|
27215
|
+
{ value: "gpt-5.4-mini-high", label: "GPT-5.4 Mini High" },
|
|
27216
|
+
{ value: "gpt-5.4-mini-xhigh", label: "GPT-5.4 Mini Extra High" },
|
|
27217
|
+
{ value: "gpt-5.4-nano-none", label: "GPT-5.4 Nano None" },
|
|
27218
|
+
{ value: "gpt-5.4-nano-low", label: "GPT-5.4 Nano Low" },
|
|
27219
|
+
{ value: "gpt-5.4-nano-medium", label: "GPT-5.4 Nano" },
|
|
27220
|
+
{ value: "gpt-5.4-nano-high", label: "GPT-5.4 Nano High" },
|
|
27221
|
+
{ value: "gpt-5.4-nano-xhigh", label: "GPT-5.4 Nano Extra High" },
|
|
27222
|
+
{ value: "grok-4-20", label: "Grok 4.20" },
|
|
27223
|
+
{ value: "grok-4-20-thinking", label: "Grok 4.20 Thinking" },
|
|
27224
|
+
{ value: "claude-4.5-sonnet", label: "Sonnet 4.5 1M" },
|
|
27225
|
+
{ value: "claude-4.5-sonnet-thinking", label: "Sonnet 4.5 1M Thinking" },
|
|
27226
|
+
{ value: "gpt-5.1-low", label: "GPT-5.1 Low" },
|
|
27227
|
+
{ value: "gpt-5.1", label: "GPT-5.1" },
|
|
27228
|
+
{ value: "gpt-5.1-high", label: "GPT-5.1 High" },
|
|
27042
27229
|
{ value: "gemini-3-flash", label: "Gemini 3 Flash" },
|
|
27043
|
-
{ value: "
|
|
27230
|
+
{ value: "gpt-5.1-codex-mini-low", label: "Codex 5.1 Mini Low" },
|
|
27231
|
+
{ value: "gpt-5.1-codex-mini", label: "Codex 5.1 Mini" },
|
|
27232
|
+
{ value: "gpt-5.1-codex-mini-high", label: "Codex 5.1 Mini High" },
|
|
27233
|
+
{ value: "claude-4-sonnet", label: "Sonnet 4" },
|
|
27234
|
+
{ value: "claude-4-sonnet-1m", label: "Sonnet 4 1M" },
|
|
27235
|
+
{ value: "claude-4-sonnet-thinking", label: "Sonnet 4 Thinking" },
|
|
27236
|
+
{ value: "claude-4-sonnet-1m-thinking", label: "Sonnet 4 1M Thinking" },
|
|
27237
|
+
{ value: "gpt-5-mini", label: "GPT-5 Mini" },
|
|
27044
27238
|
{ value: "kimi-k2.5", label: "Kimi K2.5" }
|
|
27045
27239
|
];
|
|
27046
27240
|
var DROID_MODEL_OPTIONS = [
|
|
@@ -27105,7 +27299,7 @@ var CLAUDE_MODEL_METADATA = {
|
|
|
27105
27299
|
"haiku": { value: "haiku", label: "Haiku" }
|
|
27106
27300
|
};
|
|
27107
27301
|
var CODEX_MODEL_METADATA = {
|
|
27108
|
-
"gpt-5.4": { value: "gpt-5.4", label: "GPT-5.4 \u2014
|
|
27302
|
+
"gpt-5.4": { value: "gpt-5.4", label: "GPT-5.4 \u2014 Frontier model for complex coding, research, and real-world work.", reasoningEfforts: ["low", "medium", "high", "xhigh"], defaultReasoningEffort: "xhigh" },
|
|
27109
27303
|
"gpt-5.3-codex": { value: "gpt-5.3-codex", label: "GPT-5.3 Codex \u2014 Frontier agentic coding model", reasoningEfforts: ["low", "medium", "high", "xhigh"], defaultReasoningEffort: "xhigh" },
|
|
27110
27304
|
"gpt-5.3-codex-spark": { value: "gpt-5.3-codex-spark", label: "GPT-5.3 Codex Spark \u2014 Ultra-fast coding model", reasoningEfforts: ["low", "medium", "high", "xhigh"], defaultReasoningEffort: "xhigh" },
|
|
27111
27305
|
"gpt-5.2-codex": { value: "gpt-5.2-codex", label: "GPT-5.2 Codex \u2014 Frontier agentic coding model", reasoningEfforts: ["low", "medium", "high", "xhigh"], defaultReasoningEffort: "xhigh" },
|
|
@@ -27121,50 +27315,99 @@ var GEMINI_MODEL_METADATA = {
|
|
|
27121
27315
|
"gemini-2.5-flash-lite": { value: "gemini-2.5-flash-lite", label: "Gemini 2.5 Flash Lite" }
|
|
27122
27316
|
};
|
|
27123
27317
|
var CURSOR_MODEL_METADATA = {
|
|
27124
|
-
"
|
|
27125
|
-
"
|
|
27126
|
-
"opus-4.5": { value: "opus-4.5", label: "Claude 4.5 Opus" },
|
|
27127
|
-
"opus-4.5-thinking": { value: "opus-4.5-thinking", label: "Claude 4.5 Opus (Thinking)" },
|
|
27128
|
-
"sonnet-4.6": { value: "sonnet-4.6", label: "Claude 4.6 Sonnet" },
|
|
27129
|
-
"sonnet-4.6-thinking": { value: "sonnet-4.6-thinking", label: "Claude 4.6 Sonnet (Thinking)" },
|
|
27130
|
-
"sonnet-4.5": { value: "sonnet-4.5", label: "Claude 4.5 Sonnet" },
|
|
27131
|
-
"sonnet-4.5-thinking": { value: "sonnet-4.5-thinking", label: "Claude 4.5 Sonnet (Thinking)" },
|
|
27318
|
+
"composer-2-fast": { value: "composer-2-fast", label: "Composer 2 Fast" },
|
|
27319
|
+
"composer-2": { value: "composer-2", label: "Composer 2" },
|
|
27132
27320
|
"composer-1.5": { value: "composer-1.5", label: "Composer 1.5" },
|
|
27133
|
-
"
|
|
27134
|
-
"gpt-5.
|
|
27135
|
-
"gpt-5.
|
|
27136
|
-
"gpt-5.
|
|
27321
|
+
"gpt-5.3-codex-low": { value: "gpt-5.3-codex-low", label: "Codex 5.3 Low" },
|
|
27322
|
+
"gpt-5.3-codex-low-fast": { value: "gpt-5.3-codex-low-fast", label: "Codex 5.3 Low Fast" },
|
|
27323
|
+
"gpt-5.3-codex": { value: "gpt-5.3-codex", label: "Codex 5.3" },
|
|
27324
|
+
"gpt-5.3-codex-fast": { value: "gpt-5.3-codex-fast", label: "Codex 5.3 Fast" },
|
|
27325
|
+
"gpt-5.3-codex-high": { value: "gpt-5.3-codex-high", label: "Codex 5.3 High" },
|
|
27326
|
+
"gpt-5.3-codex-high-fast": { value: "gpt-5.3-codex-high-fast", label: "Codex 5.3 High Fast" },
|
|
27327
|
+
"gpt-5.3-codex-xhigh": { value: "gpt-5.3-codex-xhigh", label: "Codex 5.3 Extra High" },
|
|
27328
|
+
"gpt-5.3-codex-xhigh-fast": { value: "gpt-5.3-codex-xhigh-fast", label: "Codex 5.3 Extra High Fast" },
|
|
27329
|
+
"gpt-5.2": { value: "gpt-5.2", label: "GPT-5.2" },
|
|
27330
|
+
"gpt-5.3-codex-spark-preview-low": { value: "gpt-5.3-codex-spark-preview-low", label: "Codex 5.3 Spark Low" },
|
|
27331
|
+
"gpt-5.3-codex-spark-preview": { value: "gpt-5.3-codex-spark-preview", label: "Codex 5.3 Spark" },
|
|
27332
|
+
"gpt-5.3-codex-spark-preview-high": { value: "gpt-5.3-codex-spark-preview-high", label: "Codex 5.3 Spark High" },
|
|
27333
|
+
"gpt-5.3-codex-spark-preview-xhigh": { value: "gpt-5.3-codex-spark-preview-xhigh", label: "Codex 5.3 Spark Extra High" },
|
|
27334
|
+
"gpt-5.2-codex-low": { value: "gpt-5.2-codex-low", label: "Codex 5.2 Low" },
|
|
27335
|
+
"gpt-5.2-codex-low-fast": { value: "gpt-5.2-codex-low-fast", label: "Codex 5.2 Low Fast" },
|
|
27336
|
+
"gpt-5.2-codex": { value: "gpt-5.2-codex", label: "Codex 5.2" },
|
|
27337
|
+
"gpt-5.2-codex-fast": { value: "gpt-5.2-codex-fast", label: "Codex 5.2 Fast" },
|
|
27338
|
+
"gpt-5.2-codex-high": { value: "gpt-5.2-codex-high", label: "Codex 5.2 High" },
|
|
27339
|
+
"gpt-5.2-codex-high-fast": { value: "gpt-5.2-codex-high-fast", label: "Codex 5.2 High Fast" },
|
|
27340
|
+
"gpt-5.2-codex-xhigh": { value: "gpt-5.2-codex-xhigh", label: "Codex 5.2 Extra High" },
|
|
27341
|
+
"gpt-5.2-codex-xhigh-fast": { value: "gpt-5.2-codex-xhigh-fast", label: "Codex 5.2 Extra High Fast" },
|
|
27342
|
+
"gpt-5.1-codex-max-low": { value: "gpt-5.1-codex-max-low", label: "Codex 5.1 Max Low" },
|
|
27343
|
+
"gpt-5.1-codex-max-low-fast": { value: "gpt-5.1-codex-max-low-fast", label: "Codex 5.1 Max Low Fast" },
|
|
27344
|
+
"gpt-5.1-codex-max-medium": { value: "gpt-5.1-codex-max-medium", label: "Codex 5.1 Max" },
|
|
27345
|
+
"gpt-5.1-codex-max-medium-fast": { value: "gpt-5.1-codex-max-medium-fast", label: "Codex 5.1 Max Medium Fast" },
|
|
27346
|
+
"gpt-5.1-codex-max-high": { value: "gpt-5.1-codex-max-high", label: "Codex 5.1 Max High" },
|
|
27347
|
+
"gpt-5.1-codex-max-high-fast": { value: "gpt-5.1-codex-max-high-fast", label: "Codex 5.1 Max High Fast" },
|
|
27348
|
+
"gpt-5.1-codex-max-xhigh": { value: "gpt-5.1-codex-max-xhigh", label: "Codex 5.1 Max Extra High" },
|
|
27349
|
+
"gpt-5.1-codex-max-xhigh-fast": { value: "gpt-5.1-codex-max-xhigh-fast", label: "Codex 5.1 Max Extra High Fast" },
|
|
27350
|
+
"claude-opus-4-7-thinking-high": { value: "claude-opus-4-7-thinking-high", label: "Opus 4.7 1M High Thinking" },
|
|
27351
|
+
"gpt-5.4-high": { value: "gpt-5.4-high", label: "GPT-5.4 1M High" },
|
|
27137
27352
|
"gpt-5.4-high-fast": { value: "gpt-5.4-high-fast", label: "GPT-5.4 High Fast" },
|
|
27138
|
-
"gpt-5.4-
|
|
27353
|
+
"gpt-5.4-xhigh-fast": { value: "gpt-5.4-xhigh-fast", label: "GPT-5.4 Extra High Fast" },
|
|
27354
|
+
"claude-4.6-opus-high-thinking-fast": { value: "claude-4.6-opus-high-thinking-fast", label: "Opus 4.6 1M Thinking Fast" },
|
|
27355
|
+
"claude-4.6-sonnet-medium": { value: "claude-4.6-sonnet-medium", label: "Sonnet 4.6 1M" },
|
|
27356
|
+
"claude-4.6-sonnet-medium-thinking": { value: "claude-4.6-sonnet-medium-thinking", label: "Sonnet 4.6 1M Thinking" },
|
|
27357
|
+
"claude-opus-4-7-low": { value: "claude-opus-4-7-low", label: "Opus 4.7 1M Low" },
|
|
27358
|
+
"claude-opus-4-7-medium": { value: "claude-opus-4-7-medium", label: "Opus 4.7 1M Medium" },
|
|
27359
|
+
"claude-opus-4-7-high": { value: "claude-opus-4-7-high", label: "Opus 4.7 1M High" },
|
|
27360
|
+
"claude-opus-4-7-xhigh": { value: "claude-opus-4-7-xhigh", label: "Opus 4.7 1M" },
|
|
27361
|
+
"claude-opus-4-7-max": { value: "claude-opus-4-7-max", label: "Opus 4.7 1M Max" },
|
|
27362
|
+
"claude-opus-4-7-thinking-low": { value: "claude-opus-4-7-thinking-low", label: "Opus 4.7 1M Low Thinking" },
|
|
27363
|
+
"claude-opus-4-7-thinking-medium": { value: "claude-opus-4-7-thinking-medium", label: "Opus 4.7 1M Medium Thinking" },
|
|
27364
|
+
"claude-opus-4-7-thinking-xhigh": { value: "claude-opus-4-7-thinking-xhigh", label: "Opus 4.7 1M Thinking" },
|
|
27365
|
+
"claude-opus-4-7-thinking-max": { value: "claude-opus-4-7-thinking-max", label: "Opus 4.7 1M Max Thinking" },
|
|
27366
|
+
"gpt-5.4-low": { value: "gpt-5.4-low", label: "GPT-5.4 1M Low" },
|
|
27367
|
+
"gpt-5.4-medium": { value: "gpt-5.4-medium", label: "GPT-5.4 1M" },
|
|
27139
27368
|
"gpt-5.4-medium-fast": { value: "gpt-5.4-medium-fast", label: "GPT-5.4 Fast" },
|
|
27140
|
-
"gpt-5.4-
|
|
27141
|
-
"
|
|
27142
|
-
"
|
|
27143
|
-
"
|
|
27144
|
-
"
|
|
27145
|
-
"
|
|
27146
|
-
"
|
|
27147
|
-
"
|
|
27148
|
-
"gpt-5.
|
|
27149
|
-
"gpt-5.
|
|
27150
|
-
"gpt-5.2-
|
|
27151
|
-
"gpt-5.2-codex-xhigh-fast": { value: "gpt-5.2-codex-xhigh-fast", label: "GPT-5.2 Codex Extra High Fast" },
|
|
27152
|
-
"gpt-5.2-codex-high": { value: "gpt-5.2-codex-high", label: "GPT-5.2 Codex High" },
|
|
27153
|
-
"gpt-5.2-codex-high-fast": { value: "gpt-5.2-codex-high-fast", label: "GPT-5.2 Codex High Fast" },
|
|
27154
|
-
"gpt-5.2-codex": { value: "gpt-5.2-codex", label: "GPT-5.2 Codex" },
|
|
27155
|
-
"gpt-5.2-codex-fast": { value: "gpt-5.2-codex-fast", label: "GPT-5.2 Codex Fast" },
|
|
27156
|
-
"gpt-5.2-codex-low": { value: "gpt-5.2-codex-low", label: "GPT-5.2 Codex Low" },
|
|
27157
|
-
"gpt-5.2-codex-low-fast": { value: "gpt-5.2-codex-low-fast", label: "GPT-5.2 Codex Low Fast" },
|
|
27158
|
-
"gpt-5.2": { value: "gpt-5.2", label: "GPT-5.2" },
|
|
27369
|
+
"gpt-5.4-xhigh": { value: "gpt-5.4-xhigh", label: "GPT-5.4 1M Extra High" },
|
|
27370
|
+
"claude-4.6-opus-high": { value: "claude-4.6-opus-high", label: "Opus 4.6 1M" },
|
|
27371
|
+
"claude-4.6-opus-max": { value: "claude-4.6-opus-max", label: "Opus 4.6 1M Max" },
|
|
27372
|
+
"claude-4.6-opus-high-thinking": { value: "claude-4.6-opus-high-thinking", label: "Opus 4.6 1M Thinking" },
|
|
27373
|
+
"claude-4.6-opus-max-thinking": { value: "claude-4.6-opus-max-thinking", label: "Opus 4.6 1M Max Thinking" },
|
|
27374
|
+
"claude-4.6-opus-max-thinking-fast": { value: "claude-4.6-opus-max-thinking-fast", label: "Opus 4.6 1M Max Thinking Fast" },
|
|
27375
|
+
"claude-4.5-opus-high": { value: "claude-4.5-opus-high", label: "Opus 4.5" },
|
|
27376
|
+
"claude-4.5-opus-high-thinking": { value: "claude-4.5-opus-high-thinking", label: "Opus 4.5 Thinking" },
|
|
27377
|
+
"gpt-5.2-low": { value: "gpt-5.2-low", label: "GPT-5.2 Low" },
|
|
27378
|
+
"gpt-5.2-low-fast": { value: "gpt-5.2-low-fast", label: "GPT-5.2 Low Fast" },
|
|
27379
|
+
"gpt-5.2-fast": { value: "gpt-5.2-fast", label: "GPT-5.2 Fast" },
|
|
27159
27380
|
"gpt-5.2-high": { value: "gpt-5.2-high", label: "GPT-5.2 High" },
|
|
27160
|
-
"gpt-5.
|
|
27161
|
-
"gpt-5.
|
|
27162
|
-
"gpt-5.
|
|
27163
|
-
"gpt-5.1-high": { value: "gpt-5.1-high", label: "GPT-5.1 High" },
|
|
27381
|
+
"gpt-5.2-high-fast": { value: "gpt-5.2-high-fast", label: "GPT-5.2 High Fast" },
|
|
27382
|
+
"gpt-5.2-xhigh": { value: "gpt-5.2-xhigh", label: "GPT-5.2 Extra High" },
|
|
27383
|
+
"gpt-5.2-xhigh-fast": { value: "gpt-5.2-xhigh-fast", label: "GPT-5.2 Extra High Fast" },
|
|
27164
27384
|
"gemini-3.1-pro": { value: "gemini-3.1-pro", label: "Gemini 3.1 Pro" },
|
|
27165
|
-
"
|
|
27385
|
+
"gpt-5.4-mini-none": { value: "gpt-5.4-mini-none", label: "GPT-5.4 Mini None" },
|
|
27386
|
+
"gpt-5.4-mini-low": { value: "gpt-5.4-mini-low", label: "GPT-5.4 Mini Low" },
|
|
27387
|
+
"gpt-5.4-mini-medium": { value: "gpt-5.4-mini-medium", label: "GPT-5.4 Mini" },
|
|
27388
|
+
"gpt-5.4-mini-high": { value: "gpt-5.4-mini-high", label: "GPT-5.4 Mini High" },
|
|
27389
|
+
"gpt-5.4-mini-xhigh": { value: "gpt-5.4-mini-xhigh", label: "GPT-5.4 Mini Extra High" },
|
|
27390
|
+
"gpt-5.4-nano-none": { value: "gpt-5.4-nano-none", label: "GPT-5.4 Nano None" },
|
|
27391
|
+
"gpt-5.4-nano-low": { value: "gpt-5.4-nano-low", label: "GPT-5.4 Nano Low" },
|
|
27392
|
+
"gpt-5.4-nano-medium": { value: "gpt-5.4-nano-medium", label: "GPT-5.4 Nano" },
|
|
27393
|
+
"gpt-5.4-nano-high": { value: "gpt-5.4-nano-high", label: "GPT-5.4 Nano High" },
|
|
27394
|
+
"gpt-5.4-nano-xhigh": { value: "gpt-5.4-nano-xhigh", label: "GPT-5.4 Nano Extra High" },
|
|
27395
|
+
"grok-4-20": { value: "grok-4-20", label: "Grok 4.20" },
|
|
27396
|
+
"grok-4-20-thinking": { value: "grok-4-20-thinking", label: "Grok 4.20 Thinking" },
|
|
27397
|
+
"claude-4.5-sonnet": { value: "claude-4.5-sonnet", label: "Sonnet 4.5 1M" },
|
|
27398
|
+
"claude-4.5-sonnet-thinking": { value: "claude-4.5-sonnet-thinking", label: "Sonnet 4.5 1M Thinking" },
|
|
27399
|
+
"gpt-5.1-low": { value: "gpt-5.1-low", label: "GPT-5.1 Low" },
|
|
27400
|
+
"gpt-5.1": { value: "gpt-5.1", label: "GPT-5.1" },
|
|
27401
|
+
"gpt-5.1-high": { value: "gpt-5.1-high", label: "GPT-5.1 High" },
|
|
27166
27402
|
"gemini-3-flash": { value: "gemini-3-flash", label: "Gemini 3 Flash" },
|
|
27167
|
-
"
|
|
27403
|
+
"gpt-5.1-codex-mini-low": { value: "gpt-5.1-codex-mini-low", label: "Codex 5.1 Mini Low" },
|
|
27404
|
+
"gpt-5.1-codex-mini": { value: "gpt-5.1-codex-mini", label: "Codex 5.1 Mini" },
|
|
27405
|
+
"gpt-5.1-codex-mini-high": { value: "gpt-5.1-codex-mini-high", label: "Codex 5.1 Mini High" },
|
|
27406
|
+
"claude-4-sonnet": { value: "claude-4-sonnet", label: "Sonnet 4" },
|
|
27407
|
+
"claude-4-sonnet-1m": { value: "claude-4-sonnet-1m", label: "Sonnet 4 1M" },
|
|
27408
|
+
"claude-4-sonnet-thinking": { value: "claude-4-sonnet-thinking", label: "Sonnet 4 Thinking" },
|
|
27409
|
+
"claude-4-sonnet-1m-thinking": { value: "claude-4-sonnet-1m-thinking", label: "Sonnet 4 1M Thinking" },
|
|
27410
|
+
"gpt-5-mini": { value: "gpt-5-mini", label: "GPT-5 Mini" },
|
|
27168
27411
|
"kimi-k2.5": { value: "kimi-k2.5", label: "Kimi K2.5" }
|
|
27169
27412
|
};
|
|
27170
27413
|
var DROID_MODEL_METADATA = {
|
|
@@ -27299,14 +27542,14 @@ var CLIRegistry = {
|
|
|
27299
27542
|
codex: {
|
|
27300
27543
|
name: "Codex CLI",
|
|
27301
27544
|
package: "@openai/codex",
|
|
27302
|
-
version: "0.
|
|
27545
|
+
version: "0.124.0",
|
|
27303
27546
|
install: "npm install -g @openai/codex",
|
|
27304
27547
|
npmLink: "https://www.npmjs.com/package/@openai/codex"
|
|
27305
27548
|
},
|
|
27306
27549
|
gemini: {
|
|
27307
27550
|
name: "Gemini CLI",
|
|
27308
27551
|
package: "@google/gemini-cli",
|
|
27309
|
-
version: "0.
|
|
27552
|
+
version: "0.39.1",
|
|
27310
27553
|
install: "npm install -g @google/gemini-cli",
|
|
27311
27554
|
npmLink: "https://www.npmjs.com/package/@google/gemini-cli"
|
|
27312
27555
|
},
|
|
@@ -27350,7 +27593,7 @@ var DefaultModels = {
|
|
|
27350
27593
|
claude: "sonnet",
|
|
27351
27594
|
codex: "gpt-5.4",
|
|
27352
27595
|
gemini: "gemini-3.1-pro-preview",
|
|
27353
|
-
cursor: "
|
|
27596
|
+
cursor: "composer-2-fast",
|
|
27354
27597
|
droid: "opus-4.6-fast",
|
|
27355
27598
|
opencode: "openai/gpt-5.2"
|
|
27356
27599
|
};
|
|
@@ -45692,7 +45935,7 @@ function isAgentStep(step) {
|
|
|
45692
45935
|
|
|
45693
45936
|
// packages/sdk/dist/workflows/runner.js
|
|
45694
45937
|
var import_node_child_process8 = require("node:child_process");
|
|
45695
|
-
var
|
|
45938
|
+
var import_node_crypto8 = require("node:crypto");
|
|
45696
45939
|
var import_node_fs20 = require("node:fs");
|
|
45697
45940
|
var import_promises8 = require("node:fs/promises");
|
|
45698
45941
|
var import_node_os8 = require("node:os");
|
|
@@ -51032,7 +51275,6 @@ var DEFAULT_ADMIN_SCOPES = [
|
|
|
51032
51275
|
"ops:read",
|
|
51033
51276
|
"admin:read"
|
|
51034
51277
|
];
|
|
51035
|
-
var JWT_HEADER = { alg: "HS256", typ: "JWT" };
|
|
51036
51278
|
function base64urlEncode(value) {
|
|
51037
51279
|
return Buffer.from(JSON.stringify(value)).toString("base64url");
|
|
51038
51280
|
}
|
|
@@ -51044,6 +51286,7 @@ function normalizeTtlSeconds(ttlSeconds) {
|
|
|
51044
51286
|
}
|
|
51045
51287
|
function mintAgentToken(opts) {
|
|
51046
51288
|
const now = Math.floor(Date.now() / 1e3);
|
|
51289
|
+
const header = { alg: "RS256", typ: "JWT", kid: opts.kid };
|
|
51047
51290
|
const payload = {
|
|
51048
51291
|
sub: `agent_${opts.agentName}`,
|
|
51049
51292
|
org: "org_relay",
|
|
@@ -51060,11 +51303,25 @@ function mintAgentToken(opts) {
|
|
|
51060
51303
|
exp: now + normalizeTtlSeconds(opts.ttlSeconds),
|
|
51061
51304
|
jti: `tok-${now}-${(0, import_node_crypto6.randomUUID)()}`
|
|
51062
51305
|
};
|
|
51063
|
-
const unsigned = `${base64urlEncode(
|
|
51064
|
-
const signature = (0, import_node_crypto6.
|
|
51306
|
+
const unsigned = `${base64urlEncode(header)}.${base64urlEncode(payload)}`;
|
|
51307
|
+
const signature = (0, import_node_crypto6.sign)("RSA-SHA256", Buffer.from(unsigned), opts.privateKey).toString("base64url");
|
|
51065
51308
|
return `${unsigned}.${signature}`;
|
|
51066
51309
|
}
|
|
51067
51310
|
|
|
51311
|
+
// packages/sdk/dist/provisioner/local-jwks.js
|
|
51312
|
+
var import_node_crypto7 = require("node:crypto");
|
|
51313
|
+
var RELAYAUTH_JWT_PRIVATE_KEY_PEM_ENV = "RELAYAUTH_JWT_PRIVATE_KEY_PEM";
|
|
51314
|
+
var RELAYAUTH_JWT_KID_ENV = "RELAYAUTH_JWT_KID";
|
|
51315
|
+
function createLocalJwksKeyPair() {
|
|
51316
|
+
const { privateKey, publicKey } = (0, import_node_crypto7.generateKeyPairSync)("rsa", { modulusLength: 2048 });
|
|
51317
|
+
const publicJwk = publicKey.export({ format: "jwk" });
|
|
51318
|
+
const kid = (0, import_node_crypto7.createHash)("sha256").update(JSON.stringify({ e: publicJwk.e, kty: "RSA", n: publicJwk.n })).digest("base64url");
|
|
51319
|
+
return { privateKey, publicJwk, kid };
|
|
51320
|
+
}
|
|
51321
|
+
function importPrivateKeyPem(privateKeyPem) {
|
|
51322
|
+
return (0, import_node_crypto7.createPrivateKey)(privateKeyPem);
|
|
51323
|
+
}
|
|
51324
|
+
|
|
51068
51325
|
// packages/sdk/dist/provisioner/index.js
|
|
51069
51326
|
var DEFAULT_AGENT_NAME = "default-agent";
|
|
51070
51327
|
function discoverAgentNames(projectDir) {
|
|
@@ -51159,7 +51416,8 @@ async function provisionWorkflowAgents(config2) {
|
|
|
51159
51416
|
permissions: agent.permissions
|
|
51160
51417
|
});
|
|
51161
51418
|
const token = mintAgentToken({
|
|
51162
|
-
|
|
51419
|
+
privateKey: config2.tokenSigningKey.privateKey,
|
|
51420
|
+
kid: config2.tokenSigningKey.kid,
|
|
51163
51421
|
agentName: agent.name,
|
|
51164
51422
|
workspace: config2.workspace,
|
|
51165
51423
|
scopes: compiled.scopes,
|
|
@@ -51183,7 +51441,8 @@ async function provisionWorkflowAgents(config2) {
|
|
|
51183
51441
|
}
|
|
51184
51442
|
const adminScopes = [...config2.adminScopes ?? DEFAULT_ADMIN_SCOPES];
|
|
51185
51443
|
const adminToken = mintAgentToken({
|
|
51186
|
-
|
|
51444
|
+
privateKey: config2.tokenSigningKey.privateKey,
|
|
51445
|
+
kid: config2.tokenSigningKey.kid,
|
|
51187
51446
|
agentName: DEFAULT_ADMIN_AGENT_NAME,
|
|
51188
51447
|
workspace: config2.workspace,
|
|
51189
51448
|
scopes: adminScopes,
|
|
@@ -55098,6 +55357,21 @@ function getWorkflowSdkSpawner(relay, cli) {
|
|
|
55098
55357
|
return null;
|
|
55099
55358
|
}
|
|
55100
55359
|
}
|
|
55360
|
+
function resolveWorkflowTokenSigningKey(env) {
|
|
55361
|
+
const privateKeyPem = env[RELAYAUTH_JWT_PRIVATE_KEY_PEM_ENV];
|
|
55362
|
+
const kid = env[RELAYAUTH_JWT_KID_ENV];
|
|
55363
|
+
if (privateKeyPem && kid) {
|
|
55364
|
+
return {
|
|
55365
|
+
privateKey: importPrivateKeyPem(privateKeyPem),
|
|
55366
|
+
kid
|
|
55367
|
+
};
|
|
55368
|
+
}
|
|
55369
|
+
const generated = createLocalJwksKeyPair();
|
|
55370
|
+
return {
|
|
55371
|
+
privateKey: generated.privateKey,
|
|
55372
|
+
kid: generated.kid
|
|
55373
|
+
};
|
|
55374
|
+
}
|
|
55101
55375
|
var WorkflowRunner = class _WorkflowRunner {
|
|
55102
55376
|
db;
|
|
55103
55377
|
workspaceId;
|
|
@@ -56043,7 +56317,7 @@ ${next}` : next;
|
|
|
56043
56317
|
this.relayApiKey = envKey;
|
|
56044
56318
|
return;
|
|
56045
56319
|
}
|
|
56046
|
-
const workspaceName = `relay-${channel}-${(0,
|
|
56320
|
+
const workspaceName = `relay-${channel}-${(0, import_node_crypto8.randomBytes)(4).toString("hex")}`;
|
|
56047
56321
|
const baseUrl = this.relayOptions.env?.RELAYCAST_BASE_URL ?? process.env.RELAYCAST_BASE_URL ?? "https://api.relaycast.dev";
|
|
56048
56322
|
const res = await fetch(`${baseUrl}/v1/workspaces`, {
|
|
56049
56323
|
method: "POST",
|
|
@@ -56243,8 +56517,9 @@ ${next}` : next;
|
|
|
56243
56517
|
...process.env,
|
|
56244
56518
|
...this.getRelayEnv() ?? {}
|
|
56245
56519
|
};
|
|
56520
|
+
const tokenSigningKey = resolveWorkflowTokenSigningKey(relayEnv);
|
|
56246
56521
|
const result = await provisionWorkflowAgents({
|
|
56247
|
-
|
|
56522
|
+
tokenSigningKey,
|
|
56248
56523
|
workspace: this.workspaceId,
|
|
56249
56524
|
projectDir: this.cwd,
|
|
56250
56525
|
relayfileBaseUrl: relayEnv.RELAYFILE_BASE_URL ?? "http://127.0.0.1:8080",
|
|
@@ -56284,7 +56559,7 @@ ${next}` : next;
|
|
|
56284
56559
|
} catch (err) {
|
|
56285
56560
|
if (err instanceof RelayError && err.code === "name_conflict") {
|
|
56286
56561
|
registration = await rc.agents.register({
|
|
56287
|
-
name: `WorkflowRunner-${(0,
|
|
56562
|
+
name: `WorkflowRunner-${(0, import_node_crypto8.randomBytes)(4).toString("hex")}`,
|
|
56288
56563
|
type: "agent"
|
|
56289
56564
|
});
|
|
56290
56565
|
} else {
|
|
@@ -60131,10 +60406,10 @@ ${excerpt}` : "";
|
|
|
60131
60406
|
}
|
|
60132
60407
|
}
|
|
60133
60408
|
generateId() {
|
|
60134
|
-
return (0,
|
|
60409
|
+
return (0, import_node_crypto8.randomBytes)(12).toString("hex");
|
|
60135
60410
|
}
|
|
60136
60411
|
generateShortId() {
|
|
60137
|
-
return (0,
|
|
60412
|
+
return (0, import_node_crypto8.randomBytes)(4).toString("hex");
|
|
60138
60413
|
}
|
|
60139
60414
|
/** Strip ANSI escape codes from terminal output — delegates to pty.ts canonical regex. */
|
|
60140
60415
|
static stripAnsi(text) {
|
|
@@ -61184,7 +61459,7 @@ function workflow(name) {
|
|
|
61184
61459
|
}
|
|
61185
61460
|
|
|
61186
61461
|
// packages/sdk/dist/workflows/coordinator.js
|
|
61187
|
-
var
|
|
61462
|
+
var import_node_crypto9 = require("node:crypto");
|
|
61188
61463
|
var import_node_events3 = require("node:events");
|
|
61189
61464
|
var PATTERN_HEURISTICS = [
|
|
61190
61465
|
// ── Dependency-based patterns (highest priority) ──────────────────────
|
|
@@ -61539,7 +61814,7 @@ var SwarmCoordinator = class extends import_node_events3.EventEmitter {
|
|
|
61539
61814
|
}
|
|
61540
61815
|
// ── Lifecycle: create run ───────────────────────────────────────────────
|
|
61541
61816
|
async createRun(workspaceId, config2) {
|
|
61542
|
-
const id = `run_${Date.now()}_${(0,
|
|
61817
|
+
const id = `run_${Date.now()}_${(0, import_node_crypto9.randomBytes)(4).toString("hex")}`;
|
|
61543
61818
|
const pattern = this.selectPattern(config2);
|
|
61544
61819
|
const now = (/* @__PURE__ */ new Date()).toISOString();
|
|
61545
61820
|
const { rows } = await this.db.query(`INSERT INTO workflow_runs (id, workspace_id, workflow_name, pattern, status, config, started_at, created_at, updated_at)
|
|
@@ -61578,7 +61853,7 @@ var SwarmCoordinator = class extends import_node_events3.EventEmitter {
|
|
|
61578
61853
|
const created = [];
|
|
61579
61854
|
for (const wf of workflows) {
|
|
61580
61855
|
for (const step of wf.steps) {
|
|
61581
|
-
const id = `step_${Date.now()}_${(0,
|
|
61856
|
+
const id = `step_${Date.now()}_${(0, import_node_crypto9.randomBytes)(4).toString("hex")}`;
|
|
61582
61857
|
const now = (/* @__PURE__ */ new Date()).toISOString();
|
|
61583
61858
|
const { rows } = await this.db.query(`INSERT INTO workflow_steps (id, run_id, step_name, agent_name, status, task, depends_on, created_at, updated_at)
|
|
61584
61859
|
VALUES ($1, $2, $3, $4, 'pending', $5, $6, $7, $7)
|
|
@@ -61755,7 +62030,7 @@ var SwarmCoordinator = class extends import_node_events3.EventEmitter {
|
|
|
61755
62030
|
};
|
|
61756
62031
|
|
|
61757
62032
|
// packages/sdk/dist/workflows/barrier.js
|
|
61758
|
-
var
|
|
62033
|
+
var import_node_crypto10 = require("node:crypto");
|
|
61759
62034
|
var import_node_events4 = require("node:events");
|
|
61760
62035
|
var BarrierManager = class extends import_node_events4.EventEmitter {
|
|
61761
62036
|
db;
|
|
@@ -61771,7 +62046,7 @@ var BarrierManager = class extends import_node_events4.EventEmitter {
|
|
|
61771
62046
|
* Create a barrier for a workflow run.
|
|
61772
62047
|
*/
|
|
61773
62048
|
async createBarrier(runId, definition) {
|
|
61774
|
-
const id = `bar_${Date.now()}_${(0,
|
|
62049
|
+
const id = `bar_${Date.now()}_${(0, import_node_crypto10.randomBytes)(4).toString("hex")}`;
|
|
61775
62050
|
const now = (/* @__PURE__ */ new Date()).toISOString();
|
|
61776
62051
|
const mode = definition.mode ?? "all";
|
|
61777
62052
|
const { rows } = await this.db.query(`INSERT INTO workflow_barriers (id, run_id, barrier_name, wait_for, resolved, is_satisfied, timeout_ms, created_at, updated_at)
|
|
@@ -61905,7 +62180,7 @@ var BarrierManager = class extends import_node_events4.EventEmitter {
|
|
|
61905
62180
|
};
|
|
61906
62181
|
|
|
61907
62182
|
// packages/sdk/dist/workflows/state.js
|
|
61908
|
-
var
|
|
62183
|
+
var import_node_crypto11 = require("node:crypto");
|
|
61909
62184
|
var import_node_events5 = require("node:events");
|
|
61910
62185
|
var StateStore = class extends import_node_events5.EventEmitter {
|
|
61911
62186
|
db;
|
|
@@ -61948,7 +62223,7 @@ var StateStore = class extends import_node_events5.EventEmitter {
|
|
|
61948
62223
|
const namespace = options.namespace ?? this.defaultNamespace;
|
|
61949
62224
|
const ttlMs = options.ttlMs ?? this.defaultTtlMs;
|
|
61950
62225
|
const expiresAt = ttlMs ? new Date(Date.now() + ttlMs).toISOString() : null;
|
|
61951
|
-
const id = `st_${Date.now()}_${(0,
|
|
62226
|
+
const id = `st_${Date.now()}_${(0, import_node_crypto11.randomBytes)(4).toString("hex")}`;
|
|
61952
62227
|
const now = (/* @__PURE__ */ new Date()).toISOString();
|
|
61953
62228
|
const { rows } = await this.db.query(`INSERT INTO swarm_state (id, run_id, namespace, key, value, expires_at, created_at, updated_at)
|
|
61954
62229
|
VALUES ($1, $2, $3, $4, $5, $6, $7, $7)
|
|
@@ -62412,6 +62687,131 @@ var TemplateRegistry = class {
|
|
|
62412
62687
|
// packages/sdk/dist/workflows/index.js
|
|
62413
62688
|
init_listr_renderer();
|
|
62414
62689
|
|
|
62690
|
+
// packages/sdk/dist/workflows/sibling-links.js
|
|
62691
|
+
function applySiblingLinks(wf, opts) {
|
|
62692
|
+
if (opts.links.length === 0) {
|
|
62693
|
+
return wf;
|
|
62694
|
+
}
|
|
62695
|
+
const stepName = opts.stepName ?? "setup-sibling-links";
|
|
62696
|
+
const dependsOn = opts.dependsOn ?? ["install-deps"];
|
|
62697
|
+
const script = buildSiblingLinkScript(opts.links);
|
|
62698
|
+
const chain = wf;
|
|
62699
|
+
chain.step(stepName, {
|
|
62700
|
+
type: "deterministic",
|
|
62701
|
+
dependsOn,
|
|
62702
|
+
command: `bash -c ${shSingleQuote(script)}`,
|
|
62703
|
+
captureOutput: true,
|
|
62704
|
+
failOnError: true
|
|
62705
|
+
});
|
|
62706
|
+
return wf;
|
|
62707
|
+
}
|
|
62708
|
+
function shSingleQuote(value) {
|
|
62709
|
+
return `'${value.replace(/'/g, `'\\''`)}'`;
|
|
62710
|
+
}
|
|
62711
|
+
function buildSiblingLinkScript(links) {
|
|
62712
|
+
const lines = ["set -euo pipefail", 'echo "=== applySiblingLinks: setting up ==="'];
|
|
62713
|
+
for (const link2 of links) {
|
|
62714
|
+
const escapedName = shSingleQuote(link2.name);
|
|
62715
|
+
const escapedPath = shSingleQuote(link2.path);
|
|
62716
|
+
lines.push(linkOneBlock(link2, escapedName, escapedPath));
|
|
62717
|
+
}
|
|
62718
|
+
lines.push('echo "=== applySiblingLinks: verifying exports ==="');
|
|
62719
|
+
for (const link2 of links) {
|
|
62720
|
+
if (!link2.expect || link2.expect.length === 0) {
|
|
62721
|
+
continue;
|
|
62722
|
+
}
|
|
62723
|
+
lines.push(verifyExportsBlock(link2));
|
|
62724
|
+
}
|
|
62725
|
+
lines.push('echo "APPLY_SIBLING_LINKS_OK"');
|
|
62726
|
+
return lines.join("\n");
|
|
62727
|
+
}
|
|
62728
|
+
function linkOneBlock(link2, escapedName, escapedPath) {
|
|
62729
|
+
void link2;
|
|
62730
|
+
return [
|
|
62731
|
+
`SIBLING_PATH=${escapedPath}`,
|
|
62732
|
+
`SIBLING_NAME=${escapedName}`,
|
|
62733
|
+
'echo "--- link: $SIBLING_NAME <- $SIBLING_PATH ---"',
|
|
62734
|
+
'if [ ! -d "$SIBLING_PATH" ]; then',
|
|
62735
|
+
' echo "SIBLING_PATH_MISSING: $SIBLING_PATH" >&2',
|
|
62736
|
+
" exit 1",
|
|
62737
|
+
"fi",
|
|
62738
|
+
'if [ -f "$SIBLING_PATH/package.json" ]; then',
|
|
62739
|
+
' echo "detected: npm"',
|
|
62740
|
+
' ( cd "$SIBLING_PATH" && npm link --silent )',
|
|
62741
|
+
' npm link --silent "$SIBLING_NAME"',
|
|
62742
|
+
'elif [ -f "$SIBLING_PATH/pyproject.toml" ] || [ -f "$SIBLING_PATH/setup.py" ] || [ -f "$SIBLING_PATH/setup.cfg" ]; then',
|
|
62743
|
+
' echo "detected: python"',
|
|
62744
|
+
// Try uv first (fastest when available), but uv refuses to install
|
|
62745
|
+
// outside a venv without --system. Pass --system explicitly so uv
|
|
62746
|
+
// works in non-venv sandboxes (common CI/agent runner shape).
|
|
62747
|
+
// If uv still fails (e.g. broken install), fall through to pip/pip3
|
|
62748
|
+
// via the explicit OR chain rather than relying on `set -e` to
|
|
62749
|
+
// short-circuit between elif branches.
|
|
62750
|
+
' if command -v uv >/dev/null 2>&1 && uv pip install --system -e "$SIBLING_PATH" --quiet 2>/dev/null; then',
|
|
62751
|
+
" :",
|
|
62752
|
+
" elif command -v pip >/dev/null 2>&1; then",
|
|
62753
|
+
' pip install -e "$SIBLING_PATH" --quiet',
|
|
62754
|
+
" elif command -v pip3 >/dev/null 2>&1; then",
|
|
62755
|
+
' pip3 install -e "$SIBLING_PATH" --quiet',
|
|
62756
|
+
" else",
|
|
62757
|
+
' echo "NO_PYTHON_INSTALLER: uv / pip / pip3 not found or all failed" >&2',
|
|
62758
|
+
" exit 1",
|
|
62759
|
+
" fi",
|
|
62760
|
+
"else",
|
|
62761
|
+
' echo "UNKNOWN_MANIFEST: expected package.json / pyproject.toml / setup.py / setup.cfg at $SIBLING_PATH" >&2',
|
|
62762
|
+
" exit 1",
|
|
62763
|
+
"fi"
|
|
62764
|
+
].join("\n");
|
|
62765
|
+
}
|
|
62766
|
+
function verifyExportsBlock(link2) {
|
|
62767
|
+
const escapedName = shSingleQuote(link2.name);
|
|
62768
|
+
const escapedPath = shSingleQuote(link2.path);
|
|
62769
|
+
const expectJson = JSON.stringify(link2.expect ?? []);
|
|
62770
|
+
return [
|
|
62771
|
+
`SIBLING_PATH=${escapedPath}`,
|
|
62772
|
+
`SIBLING_NAME=${escapedName}`,
|
|
62773
|
+
`EXPECT=${shSingleQuote(expectJson)}`,
|
|
62774
|
+
'if [ -f "$SIBLING_PATH/package.json" ]; then',
|
|
62775
|
+
nodeVerifyCommand(),
|
|
62776
|
+
"else",
|
|
62777
|
+
pythonVerifyCommand(),
|
|
62778
|
+
"fi"
|
|
62779
|
+
].join("\n");
|
|
62780
|
+
}
|
|
62781
|
+
function nodeVerifyCommand() {
|
|
62782
|
+
const script = [
|
|
62783
|
+
"const want = JSON.parse(process.env.APPLY_SIBLING_LINKS_EXPECT);",
|
|
62784
|
+
"const name = process.env.APPLY_SIBLING_LINKS_NAME;",
|
|
62785
|
+
"const mod = await import(name);",
|
|
62786
|
+
"const missing = want.filter((k) => !(k in mod));",
|
|
62787
|
+
"if (missing.length) {",
|
|
62788
|
+
' console.error(`MISSING_EXPORTS in ${name}: ${missing.join(",")}`);',
|
|
62789
|
+
" process.exit(1);",
|
|
62790
|
+
"}",
|
|
62791
|
+
'console.log(`${name} OK: ${want.join(",")}`);'
|
|
62792
|
+
].join(" ");
|
|
62793
|
+
return ` APPLY_SIBLING_LINKS_NAME="$SIBLING_NAME" APPLY_SIBLING_LINKS_EXPECT="$EXPECT" node --input-type=module -e ${shSingleQuote(script)}`;
|
|
62794
|
+
}
|
|
62795
|
+
function pythonVerifyCommand() {
|
|
62796
|
+
const script = [
|
|
62797
|
+
"import json, os, importlib",
|
|
62798
|
+
'name = os.environ["APPLY_SIBLING_LINKS_NAME"]',
|
|
62799
|
+
'want = json.loads(os.environ["APPLY_SIBLING_LINKS_EXPECT"])',
|
|
62800
|
+
"mod = importlib.import_module(name)",
|
|
62801
|
+
"missing = [k for k in want if not hasattr(mod, k)]",
|
|
62802
|
+
'sep = ","',
|
|
62803
|
+
"if missing:",
|
|
62804
|
+
' print(f"MISSING_EXPORTS in {name}: {sep.join(missing)}", flush=True)',
|
|
62805
|
+
" raise SystemExit(1)",
|
|
62806
|
+
'print(f"{name} OK: {sep.join(want)}", flush=True)'
|
|
62807
|
+
].join("\n");
|
|
62808
|
+
return [
|
|
62809
|
+
' APPLY_SIBLING_LINKS_NAME="$SIBLING_NAME" APPLY_SIBLING_LINKS_EXPECT="$EXPECT" \\',
|
|
62810
|
+
` python3 -c ${shSingleQuote(script)} 2>/dev/null || \\`,
|
|
62811
|
+
` APPLY_SIBLING_LINKS_NAME="$SIBLING_NAME" APPLY_SIBLING_LINKS_EXPECT="$EXPECT" python -c ${shSingleQuote(script)}`
|
|
62812
|
+
].join("\n");
|
|
62813
|
+
}
|
|
62814
|
+
|
|
62415
62815
|
// packages/utils/dist/name-generator.js
|
|
62416
62816
|
var ADJECTIVES = [
|
|
62417
62817
|
"Blue",
|
|
@@ -63158,10 +63558,10 @@ function checkForUpdatesInBackground(currentVersion) {
|
|
|
63158
63558
|
}
|
|
63159
63559
|
|
|
63160
63560
|
// packages/utils/dist/error-tracking.js
|
|
63161
|
-
var
|
|
63561
|
+
var import_node_crypto12 = require("node:crypto");
|
|
63162
63562
|
function generateErrorId() {
|
|
63163
63563
|
const timestamp = Math.floor(Date.now() / 1e3);
|
|
63164
|
-
const random = (0,
|
|
63564
|
+
const random = (0, import_node_crypto12.randomBytes)(2).toString("hex");
|
|
63165
63565
|
return `ERR-${timestamp}-${random}`;
|
|
63166
63566
|
}
|
|
63167
63567
|
function createTraceableError(message, context = {}, originalError) {
|
|
@@ -63503,7 +63903,7 @@ function clearBinaryCache() {
|
|
|
63503
63903
|
|
|
63504
63904
|
// packages/utils/dist/client-helpers.js
|
|
63505
63905
|
var import_node_net = require("node:net");
|
|
63506
|
-
var
|
|
63906
|
+
var import_node_crypto13 = require("node:crypto");
|
|
63507
63907
|
|
|
63508
63908
|
// packages/utils/dist/legacy-protocol.js
|
|
63509
63909
|
var PROTOCOL_VERSION2 = 1;
|
|
@@ -63630,14 +64030,14 @@ function createRequestHandler(socketPath, envelope, options) {
|
|
|
63630
64030
|
});
|
|
63631
64031
|
}
|
|
63632
64032
|
function generateRequestId(prefix = "") {
|
|
63633
|
-
return `${prefix}${Date.now().toString(36)}-${(0,
|
|
64033
|
+
return `${prefix}${Date.now().toString(36)}-${(0, import_node_crypto13.randomUUID)().slice(0, 8)}`;
|
|
63634
64034
|
}
|
|
63635
64035
|
|
|
63636
64036
|
// packages/hooks/dist/types.js
|
|
63637
64037
|
var HOOK_ABI_VERSION = PROTOCOL_VERSION;
|
|
63638
64038
|
|
|
63639
64039
|
// packages/hooks/dist/registry.js
|
|
63640
|
-
var
|
|
64040
|
+
var import_node_crypto15 = require("node:crypto");
|
|
63641
64041
|
var InMemoryHookMemory = class {
|
|
63642
64042
|
store = /* @__PURE__ */ new Map();
|
|
63643
64043
|
get(key) {
|
|
@@ -63686,8 +64086,8 @@ var HookRegistry = class {
|
|
|
63686
64086
|
injectFn;
|
|
63687
64087
|
sendFn;
|
|
63688
64088
|
constructor(options = {}) {
|
|
63689
|
-
this.sessionId = (0,
|
|
63690
|
-
this.agentId = options.agentId ?? (0,
|
|
64089
|
+
this.sessionId = (0, import_node_crypto15.randomUUID)();
|
|
64090
|
+
this.agentId = options.agentId ?? (0, import_node_crypto15.randomUUID)();
|
|
63691
64091
|
this.agentName = options.agentName ?? "agent";
|
|
63692
64092
|
this.workingDir = options.workingDir ?? process.cwd();
|
|
63693
64093
|
this.projectId = options.projectId ?? "default";
|
|
@@ -64091,7 +64491,7 @@ var HookRegistry = class {
|
|
|
64091
64491
|
var import_node_child_process11 = require("node:child_process");
|
|
64092
64492
|
|
|
64093
64493
|
// packages/config/dist/project-namespace.js
|
|
64094
|
-
var
|
|
64494
|
+
var import_node_crypto16 = __toESM(require("node:crypto"), 1);
|
|
64095
64495
|
var import_node_path35 = __toESM(require("node:path"), 1);
|
|
64096
64496
|
var import_node_fs27 = __toESM(require("node:fs"), 1);
|
|
64097
64497
|
var import_node_os13 = __toESM(require("node:os"), 1);
|
|
@@ -64109,7 +64509,7 @@ var GLOBAL_BASE_DIR2 = getGlobalBaseDir2();
|
|
|
64109
64509
|
var PROJECT_DATA_DIR = ".agent-relay";
|
|
64110
64510
|
function hashPath(projectPath) {
|
|
64111
64511
|
const normalized = import_node_path35.default.resolve(projectPath);
|
|
64112
|
-
const hash2 =
|
|
64512
|
+
const hash2 = import_node_crypto16.default.createHash("sha256").update(normalized).digest("hex");
|
|
64113
64513
|
return hash2.substring(0, 12);
|
|
64114
64514
|
}
|
|
64115
64515
|
function findProjectRoot(startDir = process.cwd()) {
|
|
@@ -64147,7 +64547,7 @@ function getProjectPaths2(projectRoot) {
|
|
|
64147
64547
|
var import_node_fs28 = require("node:fs");
|
|
64148
64548
|
var import_node_path36 = require("node:path");
|
|
64149
64549
|
var import_node_os14 = require("node:os");
|
|
64150
|
-
var
|
|
64550
|
+
var import_node_crypto17 = require("node:crypto");
|
|
64151
64551
|
function getAgentRelayConfigDir() {
|
|
64152
64552
|
return process.env.AGENT_RELAY_CONFIG_DIR ?? (0, import_node_path36.join)((0, import_node_os14.homedir)(), ".config", "agent-relay");
|
|
64153
64553
|
}
|
|
@@ -64189,7 +64589,7 @@ function shouldStoreInRepo(projectRoot) {
|
|
|
64189
64589
|
}
|
|
64190
64590
|
function getProjectHash(projectRoot) {
|
|
64191
64591
|
const root = projectRoot ?? getProjectPaths2().projectRoot;
|
|
64192
|
-
return (0,
|
|
64592
|
+
return (0, import_node_crypto17.createHash)("sha256").update(root).digest("hex").slice(0, 16);
|
|
64193
64593
|
}
|
|
64194
64594
|
function getUserTrajectoriesDir(projectRoot) {
|
|
64195
64595
|
const projectHash = getProjectHash(projectRoot);
|
|
@@ -64980,12 +65380,14 @@ init_dist2();
|
|
|
64980
65380
|
WorkflowRunner,
|
|
64981
65381
|
WorkflowStepLifecycleExecutor,
|
|
64982
65382
|
WorkflowTrajectory,
|
|
65383
|
+
applySiblingLinks,
|
|
64983
65384
|
benchmarkPatterns,
|
|
64984
65385
|
brokerLog,
|
|
64985
65386
|
buildBlockReason,
|
|
64986
65387
|
buildCommand,
|
|
64987
65388
|
buildModelSwitchCommand,
|
|
64988
65389
|
buildNormalizedProxyEnv,
|
|
65390
|
+
buildSiblingLinkScript,
|
|
64989
65391
|
checkCustom,
|
|
64990
65392
|
checkExitCode,
|
|
64991
65393
|
checkFileExists,
|