@opengeni/contracts 2.7.0 → 2.9.2-canary.1
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/agent-authored-durable-text.d.ts +3 -0
- package/dist/atlassian.js +2 -1
- package/dist/chunk-4IVHBXRI.js +221 -0
- package/dist/chunk-4IVHBXRI.js.map +1 -0
- package/dist/{chunk-ILB4IYNN.js → chunk-UGGTRQNU.js} +273 -249
- package/dist/chunk-UGGTRQNU.js.map +1 -0
- package/dist/company-profile.d.ts +275 -1
- package/dist/connection-authority.js +2 -1
- package/dist/connection-authority.js.map +1 -1
- package/dist/google-drive.js +2 -1
- package/dist/google-drive.js.map +1 -1
- package/dist/index.d.ts +282 -3
- package/dist/index.js +71 -5
- package/dist/managed-auth-session-sets.d.ts +19 -0
- package/dist/managed-auth-session-sets.js +12 -1
- package/dist/managed-auth-session-sets.js.map +1 -1
- package/dist/model-picker-order.d.ts +23 -0
- package/dist/model-picker-order.js +31 -0
- package/dist/model-picker-order.js.map +1 -0
- package/dist/organization-membership-lifecycle.d.ts +3 -0
- package/dist/permissions.d.ts +1 -0
- package/dist/personal-github.js +2 -1
- package/dist/personal-github.js.map +1 -1
- package/dist/session-titles.d.ts +9 -0
- package/dist/session-titles.js +17 -0
- package/dist/session-titles.js.map +1 -0
- package/package.json +9 -1
- package/src/agent-authored-durable-text.ts +13 -6
- package/src/company-profile.ts +46 -1
- package/src/index.ts +472 -180
- package/src/managed-auth-session-sets.ts +18 -0
- package/src/model-picker-order.ts +75 -0
- package/src/permissions.ts +1 -0
- package/src/session-titles.ts +12 -5
- package/dist/chunk-ILB4IYNN.js.map +0 -1
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
ConnectorDocumentDestination
|
|
3
3
|
} from "./chunk-WYBDERIY.js";
|
|
4
|
+
import {
|
|
5
|
+
normalizeAutomaticSessionTitle
|
|
6
|
+
} from "./chunk-4IVHBXRI.js";
|
|
4
7
|
import {
|
|
5
8
|
XaiProviderAccountAuthoritySnapshotV1
|
|
6
9
|
} from "./chunk-CM6BMECR.js";
|
|
@@ -48,6 +51,7 @@ var Permission = z.enum([
|
|
|
48
51
|
"api_keys:manage",
|
|
49
52
|
"connections:read",
|
|
50
53
|
"connections:write",
|
|
54
|
+
"capabilities:manage",
|
|
51
55
|
/** @deprecated alias of variable-sets:manage */
|
|
52
56
|
"environments:manage",
|
|
53
57
|
/** @deprecated alias of variable-sets:use */
|
|
@@ -4389,218 +4393,6 @@ var SandboxFileArtifactReceipt = z13.object({
|
|
|
4389
4393
|
}
|
|
4390
4394
|
});
|
|
4391
4395
|
|
|
4392
|
-
// src/session-titles.ts
|
|
4393
|
-
var SESSION_TITLE_MAX_CHARACTERS = 200;
|
|
4394
|
-
var AUTOMATIC_SESSION_TITLE_MAX_GRAPHEMES = 80;
|
|
4395
|
-
var AUTOMATIC_SESSION_TITLE_FALLBACK = "New conversation";
|
|
4396
|
-
var titleSegmenter;
|
|
4397
|
-
var KNOWN_SENSITIVE_VALUE_PATTERNS = [
|
|
4398
|
-
/-----BEGIN [A-Z ]*PRIVATE KEY-----/iu,
|
|
4399
|
-
/\bBearer\s+[A-Za-z0-9._~+/=-]{8,}/iu,
|
|
4400
|
-
/\b(?:sk-(?:proj-)?|gh[oprsu]_|github_pat_|glpat-|xox[baprs]-)[A-Za-z0-9_-]{8,}/iu,
|
|
4401
|
-
/\bAKIA[0-9A-Z]{16}\b/u,
|
|
4402
|
-
/\bAIza[0-9A-Za-z_-]{20,}\b/u,
|
|
4403
|
-
/\beyJ[A-Za-z0-9_-]+\.eyJ[A-Za-z0-9_-]+\.[A-Za-z0-9_-]+\b/u,
|
|
4404
|
-
/[?&](?:access_token|api_key|apikey|password|secret|token)=[^\s&#]+/iu
|
|
4405
|
-
];
|
|
4406
|
-
var URI_SCHEME_CANDIDATE_PATTERN = /\b[a-z][a-z0-9+.-]*:\S+/giu;
|
|
4407
|
-
var WINDOWS_DRIVE_PATH_PATTERN = /^[a-z]:[\\/](?![\\/])[^:]*$/iu;
|
|
4408
|
-
var SCHEMELESS_HOST_CANDIDATE_PATTERN = /\b(?:www\.)?(?:[a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?\.)+[a-z](?:[a-z0-9-]{0,61}[a-z0-9])?(?::\d{1,5})?(?:[/?#][^\s]*)?/giu;
|
|
4409
|
-
var SCHEMELESS_LOCAL_NETWORK_PATTERNS = [
|
|
4410
|
-
/\blocalhost(?:(?::\d{1,5})(?:[/?#][^\s]*)?|[/?#][^\s]*)/iu,
|
|
4411
|
-
/\b(?:(?:25[0-5]|2[0-4]\d|1?\d?\d)\.){3}(?:25[0-5]|2[0-4]\d|1?\d?\d)(?:(?::\d{1,5})(?:[/?#][^\s]*)?|[/?#][^\s]*)/u,
|
|
4412
|
-
/\[(?=[0-9a-f:.]*:[0-9a-f:.]*\])[0-9a-f:.]+\](?:(?::\d{1,5})(?:[/?#][^\s]*)?|[/?#][^\s]*)/iu
|
|
4413
|
-
];
|
|
4414
|
-
var FILE_LIKE_HOST_SUFFIXES = /* @__PURE__ */ new Set([
|
|
4415
|
-
"css",
|
|
4416
|
-
"html",
|
|
4417
|
-
"js",
|
|
4418
|
-
"json",
|
|
4419
|
-
"jsx",
|
|
4420
|
-
"lock",
|
|
4421
|
-
"md",
|
|
4422
|
-
"sql",
|
|
4423
|
-
"toml",
|
|
4424
|
-
"ts",
|
|
4425
|
-
"tsx",
|
|
4426
|
-
"xml",
|
|
4427
|
-
"yaml",
|
|
4428
|
-
"yml"
|
|
4429
|
-
]);
|
|
4430
|
-
var DOTTED_TECHNOLOGY_PATH_AUTHORITIES = /* @__PURE__ */ new Set([
|
|
4431
|
-
"ASP.NET",
|
|
4432
|
-
"AWS.SDK",
|
|
4433
|
-
"Microsoft.Extensions",
|
|
4434
|
-
"System.IO"
|
|
4435
|
-
]);
|
|
4436
|
-
var SECRET_ASSIGNMENT_CANDIDATE_PATTERN = /(?:^|[^A-Za-z0-9])(?:(['"])([A-Za-z][A-Za-z0-9_. -]*)\1|([A-Za-z][A-Za-z0-9_.-]*))\s*[=:]\s*[^\s,;]+/gu;
|
|
4437
|
-
var SECRET_LABEL_ASSIGNMENT_PATTERN = /\b(?:api[ _-]?key|access[ _-]?token|auth[ _-]?token|credential|credentials|password|passwd|private[ _-]?key|secret|token)\b\s*[=:]\s*[^\s,;]+/iu;
|
|
4438
|
-
var SENSITIVE_ASSIGNMENT_KEY_SUFFIXES = /* @__PURE__ */ new Set([
|
|
4439
|
-
"credential",
|
|
4440
|
-
"credentials",
|
|
4441
|
-
"password",
|
|
4442
|
-
"passwd",
|
|
4443
|
-
"secret",
|
|
4444
|
-
"token"
|
|
4445
|
-
]);
|
|
4446
|
-
var COMPACT_SENSITIVE_ASSIGNMENT_KEY_SUFFIXES = [
|
|
4447
|
-
"apikey",
|
|
4448
|
-
"accesskey",
|
|
4449
|
-
"accesskeyid",
|
|
4450
|
-
"accesstoken",
|
|
4451
|
-
"authtoken",
|
|
4452
|
-
"credential",
|
|
4453
|
-
"credentials",
|
|
4454
|
-
"password",
|
|
4455
|
-
"passwd",
|
|
4456
|
-
"privatekey",
|
|
4457
|
-
"secret",
|
|
4458
|
-
"secretkey",
|
|
4459
|
-
"token"
|
|
4460
|
-
];
|
|
4461
|
-
var SENSITIVE_ASSIGNMENT_KEY_WORD_SUFFIXES = [
|
|
4462
|
-
["api", "key"],
|
|
4463
|
-
["access", "key"],
|
|
4464
|
-
["access", "key", "id"],
|
|
4465
|
-
["auth", "key"],
|
|
4466
|
-
["private", "key"],
|
|
4467
|
-
["secret", "key"]
|
|
4468
|
-
];
|
|
4469
|
-
function hasWordSuffix(words, suffix) {
|
|
4470
|
-
if (words.length < suffix.length) return false;
|
|
4471
|
-
const offset = words.length - suffix.length;
|
|
4472
|
-
return suffix.every((word, index) => words[offset + index] === word);
|
|
4473
|
-
}
|
|
4474
|
-
function containsSensitiveAssignment(value) {
|
|
4475
|
-
for (const match of value.matchAll(SECRET_ASSIGNMENT_CANDIDATE_PATTERN)) {
|
|
4476
|
-
const key = match[2] ?? match[3];
|
|
4477
|
-
if (!key) continue;
|
|
4478
|
-
const words = key.replace(/([a-z0-9])([A-Z])/g, "$1 $2").replace(/([A-Z]+)([A-Z][a-z])/g, "$1 $2").toLowerCase().split(/[^a-z0-9]+/).filter(Boolean);
|
|
4479
|
-
const last = words.at(-1);
|
|
4480
|
-
if (last && SENSITIVE_ASSIGNMENT_KEY_SUFFIXES.has(last)) return true;
|
|
4481
|
-
if (last && COMPACT_SENSITIVE_ASSIGNMENT_KEY_SUFFIXES.some((suffix) => last.endsWith(suffix))) {
|
|
4482
|
-
return true;
|
|
4483
|
-
}
|
|
4484
|
-
if (SENSITIVE_ASSIGNMENT_KEY_WORD_SUFFIXES.some((suffix) => hasWordSuffix(words, suffix))) {
|
|
4485
|
-
return true;
|
|
4486
|
-
}
|
|
4487
|
-
}
|
|
4488
|
-
return false;
|
|
4489
|
-
}
|
|
4490
|
-
function containsUriScheme(value) {
|
|
4491
|
-
for (const match of value.matchAll(URI_SCHEME_CANDIDATE_PATTERN)) {
|
|
4492
|
-
if (!WINDOWS_DRIVE_PATH_PATTERN.test(match[0])) return true;
|
|
4493
|
-
}
|
|
4494
|
-
return false;
|
|
4495
|
-
}
|
|
4496
|
-
function isDottedTechnologyPath(candidate) {
|
|
4497
|
-
if (/[?:#]/u.test(candidate)) return false;
|
|
4498
|
-
const [authority, ...pathSegments] = candidate.split("/");
|
|
4499
|
-
if (!authority || pathSegments.length === 0 || pathSegments.some((segment) => !segment)) {
|
|
4500
|
-
return false;
|
|
4501
|
-
}
|
|
4502
|
-
if (!DOTTED_TECHNOLOGY_PATH_AUTHORITIES.has(authority) || pathSegments.some((segment) => !/^[A-Z][A-Za-z0-9_-]*$/u.test(segment))) {
|
|
4503
|
-
return false;
|
|
4504
|
-
}
|
|
4505
|
-
return true;
|
|
4506
|
-
}
|
|
4507
|
-
function containsSchemelessUrl(value) {
|
|
4508
|
-
if (SCHEMELESS_LOCAL_NETWORK_PATTERNS.some((pattern) => pattern.test(value))) return true;
|
|
4509
|
-
for (const match of value.matchAll(SCHEMELESS_HOST_CANDIDATE_PATTERN)) {
|
|
4510
|
-
const candidate = match[0];
|
|
4511
|
-
if (candidate.toLowerCase().startsWith("www.")) return true;
|
|
4512
|
-
if (!/[/?#]/u.test(candidate)) continue;
|
|
4513
|
-
const authority = candidate.split(/[/?#]/u, 1)[0] ?? "";
|
|
4514
|
-
const hostname = authority.replace(/:\d{1,5}$/u, "");
|
|
4515
|
-
const suffix = hostname.split(".").at(-1)?.toLowerCase();
|
|
4516
|
-
if (suffix && FILE_LIKE_HOST_SUFFIXES.has(suffix)) continue;
|
|
4517
|
-
if (isDottedTechnologyPath(candidate)) continue;
|
|
4518
|
-
return true;
|
|
4519
|
-
}
|
|
4520
|
-
return false;
|
|
4521
|
-
}
|
|
4522
|
-
var OPAQUE_IDENTIFIER_PATTERN = /\b(?=[A-Za-z0-9_-]{32,}\b)(?=[A-Za-z0-9_-]*[A-Za-z])(?=[A-Za-z0-9_-]*\d)[A-Za-z0-9_-]+\b/u;
|
|
4523
|
-
var DEFAULT_IGNORABLE_CODE_POINTS = /\p{Default_Ignorable_Code_Point}+/gu;
|
|
4524
|
-
var ESCAPED_QUOTE_DELIMITERS = /\\+(?=["'])/gu;
|
|
4525
|
-
var TITLE_LABEL_PATTERN = /^(?:(?:suggested|generated|concise)\s+)?(?:(?:session|chat|conversation|task)\s+)?title\s*[:\-–—]\s*/iu;
|
|
4526
|
-
var LEADING_BOILERPLATE_PATTERNS = [
|
|
4527
|
-
/^(?:hi|hello|hey)(?:\s+there)?\s*[,!:.\-–—]*\s*/iu,
|
|
4528
|
-
/^(?:i\s+(?:would\s+like|want|need)\s+you\s+to|i['’]d\s+like\s+you\s+to)\s+/iu,
|
|
4529
|
-
/^(?:please\s+)?(?:can|could|would|will)\s+you\s+/iu,
|
|
4530
|
-
/^(?:your|the)\s+(?:task|job)\s+is\s+to\s+/iu,
|
|
4531
|
-
/^(?:please\s+)?help\s+me\s+(?:to\s+)?/iu,
|
|
4532
|
-
/^please(?:\s*[,!:.\-–—]+\s*|\s+|$)/iu
|
|
4533
|
-
];
|
|
4534
|
-
function automaticTitleDetectionValue(value) {
|
|
4535
|
-
return value.normalize("NFKC").replace(DEFAULT_IGNORABLE_CODE_POINTS, "").replace(ESCAPED_QUOTE_DELIMITERS, "");
|
|
4536
|
-
}
|
|
4537
|
-
function hasVisibleAutomaticTitleContent(value) {
|
|
4538
|
-
return automaticTitleDetectionValue(value).trim().length > 0;
|
|
4539
|
-
}
|
|
4540
|
-
function containsSensitiveAutomaticTitleValue(value) {
|
|
4541
|
-
const detectionValue = automaticTitleDetectionValue(value);
|
|
4542
|
-
if (KNOWN_SENSITIVE_VALUE_PATTERNS.some((pattern) => pattern.test(detectionValue))) return true;
|
|
4543
|
-
if (containsUriScheme(detectionValue)) return true;
|
|
4544
|
-
if (containsSchemelessUrl(detectionValue)) return true;
|
|
4545
|
-
if (SECRET_LABEL_ASSIGNMENT_PATTERN.test(detectionValue)) return true;
|
|
4546
|
-
if (containsSensitiveAssignment(detectionValue)) return true;
|
|
4547
|
-
if (OPAQUE_IDENTIFIER_PATTERN.test(detectionValue)) return true;
|
|
4548
|
-
return false;
|
|
4549
|
-
}
|
|
4550
|
-
function stripAutomaticTitleBoilerplate(value) {
|
|
4551
|
-
let title = value;
|
|
4552
|
-
for (let pass = 0; pass < 4; pass += 1) {
|
|
4553
|
-
const before = title;
|
|
4554
|
-
title = title.replace(/^(?:```[^\n]*|[\s#>*_`"'“”‘’\-–—]+)+/u, "").replace(TITLE_LABEL_PATTERN, "");
|
|
4555
|
-
for (const pattern of LEADING_BOILERPLATE_PATTERNS) {
|
|
4556
|
-
title = title.replace(pattern, "");
|
|
4557
|
-
}
|
|
4558
|
-
title = title.trim();
|
|
4559
|
-
if (title === before) break;
|
|
4560
|
-
}
|
|
4561
|
-
return title;
|
|
4562
|
-
}
|
|
4563
|
-
function automaticTitleGraphemes(value) {
|
|
4564
|
-
if (titleSegmenter === void 0) {
|
|
4565
|
-
titleSegmenter = typeof Intl.Segmenter === "function" ? new Intl.Segmenter(void 0, { granularity: "grapheme" }) : null;
|
|
4566
|
-
}
|
|
4567
|
-
if (titleSegmenter) {
|
|
4568
|
-
return Array.from(titleSegmenter.segment(value), (part) => part.segment);
|
|
4569
|
-
}
|
|
4570
|
-
const graphemes = [];
|
|
4571
|
-
for (const point of value) {
|
|
4572
|
-
const prior = graphemes.at(-1);
|
|
4573
|
-
if (prior && (/^[\p{Mark}\u{FE0E}\u{FE0F}\p{Emoji_Modifier}]$/u.test(point) || point === "\u200D" || prior.endsWith("\u200D"))) {
|
|
4574
|
-
graphemes[graphemes.length - 1] = `${prior}${point}`;
|
|
4575
|
-
} else {
|
|
4576
|
-
graphemes.push(point);
|
|
4577
|
-
}
|
|
4578
|
-
}
|
|
4579
|
-
return graphemes;
|
|
4580
|
-
}
|
|
4581
|
-
function boundAutomaticTitle(value) {
|
|
4582
|
-
const words = value.split(/\s+/u);
|
|
4583
|
-
const wordBounded = words.length > 10 ? words.slice(0, 10).join(" ") : value;
|
|
4584
|
-
const graphemes = automaticTitleGraphemes(wordBounded);
|
|
4585
|
-
if (graphemes.length <= AUTOMATIC_SESSION_TITLE_MAX_GRAPHEMES) return wordBounded;
|
|
4586
|
-
const prefix = graphemes.slice(0, AUTOMATIC_SESSION_TITLE_MAX_GRAPHEMES).join("");
|
|
4587
|
-
const lastWhitespace = prefix.search(/\s+\S*$/u);
|
|
4588
|
-
return (lastWhitespace >= 16 ? prefix.slice(0, lastWhitespace) : prefix).trimEnd();
|
|
4589
|
-
}
|
|
4590
|
-
function normalizeAutomaticSessionTitle(value) {
|
|
4591
|
-
const firstLine = value.replace(/[\u0000-\u001f\u007f-\u009f]+/gu, "\n").split(/\n+/u).map((line) => line.trim()).find(Boolean);
|
|
4592
|
-
if (!firstLine || !hasVisibleAutomaticTitleContent(firstLine) || containsSensitiveAutomaticTitleValue(firstLine)) {
|
|
4593
|
-
return null;
|
|
4594
|
-
}
|
|
4595
|
-
let title = stripAutomaticTitleBoilerplate(firstLine).replace(/\s+/gu, " ").replace(/[\s.!?,;:\-–—]+$/u, "").trim();
|
|
4596
|
-
if (!title || !hasVisibleAutomaticTitleContent(title) || containsSensitiveAutomaticTitleValue(title)) {
|
|
4597
|
-
return null;
|
|
4598
|
-
}
|
|
4599
|
-
title = boundAutomaticTitle(title).replace(/[\s.!?,;:\-–—]+$/u, "").trim();
|
|
4600
|
-
if (!title || !hasVisibleAutomaticTitleContent(title)) return null;
|
|
4601
|
-
return title;
|
|
4602
|
-
}
|
|
4603
|
-
|
|
4604
4396
|
// src/agent-topology.ts
|
|
4605
4397
|
import { z as z15 } from "zod";
|
|
4606
4398
|
|
|
@@ -6238,10 +6030,12 @@ var AGENT_AUTHORED_COMPANY_PROFILE_SCALAR_MAX_CHARS = 400;
|
|
|
6238
6030
|
var AGENT_AUTHORED_COMPANY_PROFILE_ENTRY_MAX_CHARS = 200;
|
|
6239
6031
|
var AGENT_AUTHORED_COMPANY_PROFILE_CONTENT_MAX_UTF8_BYTES = 4096;
|
|
6240
6032
|
var AGENT_AUTHORED_INSTRUCTION_POLICY_CONTENT_TOO_LONG_MESSAGE = `A workspace rule is composed verbatim into the prompt of every session it applies to (every session for a global charter or policy, every session bound to the role for a role policy), for as long as it stays active. Keep it under ${AGENT_AUTHORED_INSTRUCTION_POLICY_CONTENT_MAX_CHARS} characters: one rule, imperative, no numbered procedure. Split unrelated rules into separate entries.`;
|
|
6241
|
-
var AGENT_AUTHORED_PREFERENCE_CONTENT_TOO_LONG_MESSAGE = `A Skill is durable Agent Knowledge that agents retrieve on demand, so its length is retrieval cost rather than standing prompt cost: only its short title and description are composed into every session prompt. Keep it under ${AGENT_AUTHORED_PREFERENCE_CONTENT_MAX_CHARS} characters: state the
|
|
6033
|
+
var AGENT_AUTHORED_PREFERENCE_CONTENT_TOO_LONG_MESSAGE = `A Skill is durable Agent Knowledge that agents retrieve on demand, so its length is retrieval cost rather than standing prompt cost: only its short title and description are composed into every session prompt. Keep it under ${AGENT_AUTHORED_PREFERENCE_CONTENT_MAX_CHARS} characters: state the trigger and outcome plainly, include only the necessary procedure, checks, and exceptions, and remove background, repeated guidance, and decorative examples.`;
|
|
6242
6034
|
var AGENT_AUTHORED_COMPANY_PROFILE_TOO_LONG_MESSAGE = `Organization identity and mission are mandatory prompt context in every root session across the organization. Keep each under ${AGENT_AUTHORED_COMPANY_PROFILE_SCALAR_MAX_CHARS} characters: one concise descriptive statement, no products, customers, goals, constraints, procedure, or marketing copy. Those details belong in organization Documents and are retrieved as evidence when relevant.`;
|
|
6243
6035
|
var AGENT_AUTHORED_REMEMBER_CONTENT_TOO_LONG_MESSAGE = `Remembered content is bounded by where it lands: a mandatory workspace rule at most ${AGENT_AUTHORED_INSTRUCTION_POLICY_CONTENT_MAX_CHARS} characters because it is composed into every session prompt it applies to, a preference at most ${AGENT_AUTHORED_PREFERENCE_CONTENT_MAX_CHARS}, a Knowledge fact at most 4000. Write one imperative statement in 1-3 sentences, split unrelated entries, and keep procedure in a Document or Skill that the entry references.`;
|
|
6244
|
-
var
|
|
6036
|
+
var AGENT_AUTHORED_INSTRUCTION_POLICY_STYLE = "Write the shortest complete imperative rule in 1-3 sentences, with no numbered procedure, examples, rationale, or restated defaults. Split unrelated rules, and move conditional procedure into a Skill.";
|
|
6037
|
+
var AGENT_AUTHORED_SKILL_STYLE = "Write one focused Skill with a clear trigger and outcome. Include only the prerequisites, necessary steps, verification, and important failure handling an agent needs to execute it; omit background, repetition, generic advice, and decorative examples. Split unrelated workflows into separate Skills.";
|
|
6038
|
+
var AGENT_AUTHORED_DURABLE_TEXT_STYLE = AGENT_AUTHORED_INSTRUCTION_POLICY_STYLE;
|
|
6245
6039
|
function agentAuthoredDurableTextTooLongMessage(input) {
|
|
6246
6040
|
const subject = input.kind === "instruction_policy" ? "This rule is" : "This preference is";
|
|
6247
6041
|
const limit = input.kind === "instruction_policy" ? AGENT_AUTHORED_INSTRUCTION_POLICY_CONTENT_TOO_LONG_MESSAGE : AGENT_AUTHORED_PREFERENCE_CONTENT_TOO_LONG_MESSAGE;
|
|
@@ -6448,6 +6242,19 @@ var CompanyProfileMutationResponse = z18.object({
|
|
|
6448
6242
|
});
|
|
6449
6243
|
var COMPANY_PROFILE_AGENT_APPROVE_OPTION = "activate";
|
|
6450
6244
|
var COMPANY_PROFILE_AGENT_REJECT_OPTION = "skip";
|
|
6245
|
+
var CompanyProfileAgentPolicyMode = z18.enum(["off", "suggest", "automatic"]);
|
|
6246
|
+
var CompanyProfileAgentPolicy = z18.object({
|
|
6247
|
+
organizationId: z18.string().uuid(),
|
|
6248
|
+
mode: CompanyProfileAgentPolicyMode,
|
|
6249
|
+
version: z18.number().int().nonnegative(),
|
|
6250
|
+
updatedAt: z18.string().datetime({ offset: true }),
|
|
6251
|
+
changed: z18.boolean().optional()
|
|
6252
|
+
});
|
|
6253
|
+
var UpdateCompanyProfileAgentPolicyRequest = z18.object({
|
|
6254
|
+
mode: CompanyProfileAgentPolicyMode,
|
|
6255
|
+
expectedVersion: z18.number().int().nonnegative(),
|
|
6256
|
+
operationId: z18.string().uuid()
|
|
6257
|
+
}).strict();
|
|
6451
6258
|
var CompanyProfileAgentAttempt = z18.object({
|
|
6452
6259
|
accountId: z18.string().uuid(),
|
|
6453
6260
|
workspaceId: z18.string().uuid(),
|
|
@@ -6466,15 +6273,29 @@ var CompanyProfileAgentHumanInputPrompt = z18.object({
|
|
|
6466
6273
|
questions: z18.array(z18.lazy(() => HumanInputQuestion)).length(1),
|
|
6467
6274
|
allowSkip: z18.literal(false)
|
|
6468
6275
|
});
|
|
6469
|
-
var
|
|
6276
|
+
var CompanyProfileAgentReviewRequiredReceipt = z18.object({
|
|
6470
6277
|
status: z18.literal("confirmation_required"),
|
|
6471
6278
|
operationId: z18.string().uuid(),
|
|
6472
6279
|
proposalReceiptId: z18.string().uuid(),
|
|
6473
6280
|
revision: CompanyProfileRevision,
|
|
6281
|
+
policyMode: z18.literal("suggest"),
|
|
6474
6282
|
humanInput: CompanyProfileAgentHumanInputPrompt,
|
|
6475
6283
|
confirmWith: z18.literal("company_profile_confirm"),
|
|
6476
6284
|
replayed: z18.boolean()
|
|
6477
6285
|
});
|
|
6286
|
+
var CompanyProfileAgentAutomaticActivationReceipt = z18.object({
|
|
6287
|
+
status: z18.literal("activated"),
|
|
6288
|
+
operationId: z18.string().uuid(),
|
|
6289
|
+
proposalReceiptId: z18.string().uuid(),
|
|
6290
|
+
automaticActivationReceiptId: z18.string().uuid(),
|
|
6291
|
+
policyMode: z18.literal("automatic"),
|
|
6292
|
+
mutation: CompanyProfileMutationResponse,
|
|
6293
|
+
replayed: z18.boolean()
|
|
6294
|
+
});
|
|
6295
|
+
var CompanyProfileAgentProposalReceipt = z18.discriminatedUnion("status", [
|
|
6296
|
+
CompanyProfileAgentReviewRequiredReceipt,
|
|
6297
|
+
CompanyProfileAgentAutomaticActivationReceipt
|
|
6298
|
+
]);
|
|
6478
6299
|
var CompanyProfileAgentConfirmRequest = z18.object({
|
|
6479
6300
|
operationId: z18.string().uuid(),
|
|
6480
6301
|
proposalReceiptId: z18.string().uuid(),
|
|
@@ -9118,9 +8939,7 @@ var FIRST_PARTY_IN_PROCESS_TOOL_NAME_SET = new Set(
|
|
|
9118
8939
|
FIRST_PARTY_IN_PROCESS_TOOL_NAMES
|
|
9119
8940
|
);
|
|
9120
8941
|
var FIRST_PARTY_COMPATIBILITY_ONLY_TOOL_NAMES = [
|
|
9121
|
-
"slack_bot_post_message"
|
|
9122
|
-
"memory_save",
|
|
9123
|
-
"memory_correct"
|
|
8942
|
+
"slack_bot_post_message"
|
|
9124
8943
|
];
|
|
9125
8944
|
var FIRST_PARTY_COMPATIBILITY_ONLY_TOOL_NAME_SET = new Set(
|
|
9126
8945
|
FIRST_PARTY_COMPATIBILITY_ONLY_TOOL_NAMES
|
|
@@ -9139,11 +8958,7 @@ var EDITABLE_ARTIFACT_MCP_CODEMODE_PATHS = {
|
|
|
9139
8958
|
editable_artifact_export_status: ["artifacts", "exportStatus"]
|
|
9140
8959
|
};
|
|
9141
8960
|
var DEFAULT_FIRST_PARTY_MCP_TOOLS = FIRST_PARTY_MCP_TOOL_NAMES.filter(
|
|
9142
|
-
(name) => (
|
|
9143
|
-
// Memory V1 writes are retired entirely; `remember` and task-note
|
|
9144
|
-
// promotion own durable agent writes.
|
|
9145
|
-
name !== "memory_save" && name !== "memory_correct" && !name.startsWith("social_") && !name.startsWith("x_") && !name.startsWith("reddit_") && !name.startsWith("slack_bot_") && !name.startsWith("fiken_") && !name.startsWith("atlassian_")
|
|
9146
|
-
)
|
|
8961
|
+
(name) => !name.startsWith("social_") && !name.startsWith("x_") && !name.startsWith("reddit_") && !name.startsWith("slack_bot_") && !name.startsWith("fiken_") && !name.startsWith("atlassian_")
|
|
9147
8962
|
);
|
|
9148
8963
|
function prefixedMcpToolName(registryId2, toolName) {
|
|
9149
8964
|
return `${registryId2}__${toolName}`;
|
|
@@ -9998,6 +9813,37 @@ var UpdateWorkspaceModelPolicyRequest = z30.object({
|
|
|
9998
9813
|
allowedProviders: z30.array(z30.string().min(1).max(128)).max(64).nullable().optional(),
|
|
9999
9814
|
allowedModels: z30.array(z30.string().min(1).max(256)).max(256).nullable().optional()
|
|
10000
9815
|
});
|
|
9816
|
+
var WORKSPACE_GATEWAY_CUSTOM_MODEL_UPSTREAM_ID_MAX_LENGTH = 238;
|
|
9817
|
+
var CreateWorkspaceGatewayCustomModelRequest = z30.object({
|
|
9818
|
+
operationId: z30.string().uuid(),
|
|
9819
|
+
upstreamModelId: z30.string().max(WORKSPACE_GATEWAY_CUSTOM_MODEL_UPSTREAM_ID_MAX_LENGTH).regex(/^[!-{}-~]+$/),
|
|
9820
|
+
label: z30.string().min(1).max(128).refine((value) => new TextEncoder().encode(value).byteLength <= 128, {
|
|
9821
|
+
message: "label must be at most 128 UTF-8 bytes"
|
|
9822
|
+
}).refine((value) => !/[\r\n|]/u.test(value), {
|
|
9823
|
+
message: "label must not contain newlines or the | field separator"
|
|
9824
|
+
}).optional()
|
|
9825
|
+
}).strict();
|
|
9826
|
+
var DeleteWorkspaceGatewayCustomModelRequest = z30.object({
|
|
9827
|
+
expectedVersion: z30.number().int().positive(),
|
|
9828
|
+
operationId: z30.string().uuid()
|
|
9829
|
+
}).strict();
|
|
9830
|
+
var WorkspaceGatewayCustomModel = z30.object({
|
|
9831
|
+
id: z30.string().uuid(),
|
|
9832
|
+
upstreamModelId: z30.string(),
|
|
9833
|
+
label: z30.string().nullable(),
|
|
9834
|
+
version: z30.number().int().positive(),
|
|
9835
|
+
createdAt: z30.string().datetime(),
|
|
9836
|
+
updatedAt: z30.string().datetime()
|
|
9837
|
+
});
|
|
9838
|
+
var WorkspaceGatewayCustomModelsResponse = z30.object({
|
|
9839
|
+
models: z30.array(WorkspaceGatewayCustomModel)
|
|
9840
|
+
});
|
|
9841
|
+
var CreateWorkspaceOpenRouterCustomModelRequest = CreateWorkspaceGatewayCustomModelRequest;
|
|
9842
|
+
var DeleteWorkspaceOpenRouterCustomModelRequest = DeleteWorkspaceGatewayCustomModelRequest;
|
|
9843
|
+
var WorkspaceOpenRouterCustomModel = WorkspaceGatewayCustomModel;
|
|
9844
|
+
var WorkspaceOpenRouterCustomModelsResponse = z30.object({
|
|
9845
|
+
models: z30.array(WorkspaceOpenRouterCustomModel)
|
|
9846
|
+
});
|
|
10001
9847
|
var turnInitiatorIdentityFields = {
|
|
10002
9848
|
subjectId: z30.string().min(1),
|
|
10003
9849
|
/** Immutable display snapshot; never an authorization input. */
|
|
@@ -10433,6 +10279,20 @@ var CreateWorkspaceRequest = z30.object({
|
|
|
10433
10279
|
// the deployment default template.
|
|
10434
10280
|
agentInstructions: z30.string().min(1).nullable().optional()
|
|
10435
10281
|
});
|
|
10282
|
+
var EnsureWorkspaceRequest = z30.object({
|
|
10283
|
+
accountId: z30.string().uuid(),
|
|
10284
|
+
externalSource: z30.string().trim().min(1).max(200),
|
|
10285
|
+
externalId: z30.string().trim().min(1).max(1024),
|
|
10286
|
+
name: z30.string().trim().min(1).max(200),
|
|
10287
|
+
slug: z30.string().trim().min(1).max(200).optional(),
|
|
10288
|
+
// White-label persona override for this workspace's agent. null/omitted uses
|
|
10289
|
+
// the deployment default template.
|
|
10290
|
+
agentInstructions: z30.string().min(1).nullable().optional()
|
|
10291
|
+
}).strict();
|
|
10292
|
+
var EnsureWorkspaceResponse = z30.object({
|
|
10293
|
+
workspace: Workspace,
|
|
10294
|
+
created: z30.boolean()
|
|
10295
|
+
}).strict();
|
|
10436
10296
|
var UpdateWorkspaceRequest = z30.object({
|
|
10437
10297
|
name: z30.string().min(1).optional(),
|
|
10438
10298
|
slug: z30.string().min(1).nullable().optional(),
|
|
@@ -10465,6 +10325,11 @@ var CreateApiKeyResponse = z30.object({
|
|
|
10465
10325
|
apiKey: ApiKey,
|
|
10466
10326
|
token: z30.string().min(1)
|
|
10467
10327
|
});
|
|
10328
|
+
var CreateOrganizationApiKeyRequest = z30.object({
|
|
10329
|
+
name: z30.string().trim().min(1).max(200),
|
|
10330
|
+
description: z30.string().trim().min(1).max(500).optional(),
|
|
10331
|
+
expiresAt: z30.string().datetime({ offset: true }).optional()
|
|
10332
|
+
}).strict();
|
|
10468
10333
|
var WorkspaceMember = z30.object({
|
|
10469
10334
|
subjectId: z30.string().min(1),
|
|
10470
10335
|
subjectLabel: z30.string().nullable(),
|
|
@@ -10475,10 +10340,20 @@ var WorkspaceMember = z30.object({
|
|
|
10475
10340
|
var ListWorkspaceMembersResponse = z30.object({
|
|
10476
10341
|
members: z30.array(WorkspaceMember)
|
|
10477
10342
|
});
|
|
10343
|
+
var WorkspaceMemberCandidate = z30.object({
|
|
10344
|
+
organizationMembershipId: z30.string().uuid(),
|
|
10345
|
+
subjectId: z30.string().min(1),
|
|
10346
|
+
name: z30.string().min(1).max(1024).nullable(),
|
|
10347
|
+
email: z30.string().email().max(320).nullable(),
|
|
10348
|
+
organizationRole: z30.enum(["owner", "admin", "member"])
|
|
10349
|
+
});
|
|
10350
|
+
var ListWorkspaceMemberCandidatesResponse = z30.object({
|
|
10351
|
+
members: z30.array(WorkspaceMemberCandidate).max(1e3)
|
|
10352
|
+
});
|
|
10478
10353
|
var AddWorkspaceMemberRequest = z30.object({
|
|
10479
|
-
//
|
|
10480
|
-
//
|
|
10481
|
-
|
|
10354
|
+
// The candidate inventory exposes this opaque organization-local identifier.
|
|
10355
|
+
// Organization invitations stay in the organization-admin lifecycle.
|
|
10356
|
+
organizationMembershipId: z30.string().uuid(),
|
|
10482
10357
|
role: z30.string().min(1).optional(),
|
|
10483
10358
|
permissions: z30.array(Permission)
|
|
10484
10359
|
});
|
|
@@ -13352,19 +13227,89 @@ function renderSessionSystemUpdateBatch(updates) {
|
|
|
13352
13227
|
})
|
|
13353
13228
|
].join("\n");
|
|
13354
13229
|
}
|
|
13355
|
-
|
|
13230
|
+
var SCHEDULED_OCCURRENCE_TASK_LABEL = "[OpenGeni scheduled task occurrence]";
|
|
13231
|
+
function renderScheduledOccurrenceTaskBatch(updates) {
|
|
13232
|
+
if (updates.length === 0 || updates.some((update) => update.kind !== "scheduled_occurrence")) {
|
|
13233
|
+
return null;
|
|
13234
|
+
}
|
|
13235
|
+
const occurrences = updates.map((update) => {
|
|
13236
|
+
const parsed = SessionSystemUpdatePayload.safeParse(update.payload);
|
|
13237
|
+
if (!parsed.success || parsed.data.type !== "scheduled_occurrence" || parsed.data.scheduledTaskRunId !== update.sourceId) {
|
|
13238
|
+
return null;
|
|
13239
|
+
}
|
|
13240
|
+
return { update, payload: parsed.data };
|
|
13241
|
+
});
|
|
13242
|
+
if (occurrences.some((occurrence) => occurrence === null)) return null;
|
|
13243
|
+
const introduction = occurrences.length === 1 ? "A new scheduled occurrence has started. Execute the instructions below for this occurrence now." : `${occurrences.length} new scheduled occurrences have started. Execute every instruction set below for this turn now.`;
|
|
13244
|
+
return [
|
|
13245
|
+
SCHEDULED_OCCURRENCE_TASK_LABEL,
|
|
13246
|
+
introduction,
|
|
13247
|
+
"The scheduled instructions below are the task for this turn. Earlier completed goals, occurrences, conversation, and tool outputs are historical context and do not complete this occurrence. When the task depends on mutable external state, query that state during this occurrence instead of reusing an earlier result.",
|
|
13248
|
+
...occurrences.flatMap((occurrence, index) => {
|
|
13249
|
+
if (!occurrence) return [];
|
|
13250
|
+
return [
|
|
13251
|
+
"",
|
|
13252
|
+
...occurrences.length > 1 ? [`Occurrence ${index + 1}:`] : [],
|
|
13253
|
+
`Scheduled task ID: ${occurrence.payload.scheduledTaskId}`,
|
|
13254
|
+
`Scheduled task run ID: ${occurrence.payload.scheduledTaskRunId}`,
|
|
13255
|
+
`Update ID: ${occurrence.update.id}`,
|
|
13256
|
+
"Instructions:",
|
|
13257
|
+
occurrence.payload.text
|
|
13258
|
+
];
|
|
13259
|
+
})
|
|
13260
|
+
].join("\n");
|
|
13261
|
+
}
|
|
13262
|
+
function sessionSystemUpdateBatchHistoryItem(updates, goalSnapshot, options = {}) {
|
|
13356
13263
|
const goalContext = renderSessionGoalContext(goalSnapshot);
|
|
13264
|
+
const scheduledTask = options.promoteScheduledOccurrenceToUser ? renderScheduledOccurrenceTaskBatch(updates) : null;
|
|
13357
13265
|
return {
|
|
13358
13266
|
type: "message",
|
|
13359
|
-
role: "system",
|
|
13267
|
+
role: scheduledTask ? "user" : "system",
|
|
13360
13268
|
content: [
|
|
13361
13269
|
...goalContext ? [`${SESSION_GOAL_CONTEXT_LABEL}
|
|
13362
13270
|
${goalContext}`] : [],
|
|
13363
|
-
renderSessionSystemUpdateBatch(updates)
|
|
13271
|
+
scheduledTask ?? renderSessionSystemUpdateBatch(updates)
|
|
13364
13272
|
].join("\n\n")
|
|
13365
13273
|
};
|
|
13366
13274
|
}
|
|
13367
13275
|
var VariableSetVariableName = z30.string().regex(/^[A-Z][A-Z0-9_]*$/).max(128);
|
|
13276
|
+
var VARIABLE_SET_RESERVED_EXACT_NAMES = [
|
|
13277
|
+
"HOME",
|
|
13278
|
+
"PATH",
|
|
13279
|
+
"SHELL",
|
|
13280
|
+
"USER",
|
|
13281
|
+
"LOGNAME",
|
|
13282
|
+
"TMPDIR",
|
|
13283
|
+
"IFS",
|
|
13284
|
+
"ENV",
|
|
13285
|
+
"BASH_ENV",
|
|
13286
|
+
"NODE_OPTIONS",
|
|
13287
|
+
"PYTHONPATH",
|
|
13288
|
+
"PYTHONSTARTUP",
|
|
13289
|
+
"PERL5OPT",
|
|
13290
|
+
"PERL5LIB",
|
|
13291
|
+
"GH_TOKEN",
|
|
13292
|
+
"GITHUB_TOKEN",
|
|
13293
|
+
"GITLAB_TOKEN",
|
|
13294
|
+
"AZURE_DEVOPS_EXT_PAT",
|
|
13295
|
+
"GIT_ASKPASS",
|
|
13296
|
+
"GIT_TERMINAL_PROMPT"
|
|
13297
|
+
];
|
|
13298
|
+
var VARIABLE_SET_RESERVED_PREFIXES = [
|
|
13299
|
+
"OPENGENI_",
|
|
13300
|
+
"GIT_CONFIG_",
|
|
13301
|
+
"GIT_AUTHOR_",
|
|
13302
|
+
"GIT_COMMITTER_",
|
|
13303
|
+
"LD_",
|
|
13304
|
+
"DYLD_"
|
|
13305
|
+
];
|
|
13306
|
+
function variableSetVariableNameReservation(name) {
|
|
13307
|
+
if (VARIABLE_SET_RESERVED_EXACT_NAMES.includes(name)) {
|
|
13308
|
+
return { kind: "exact", value: name };
|
|
13309
|
+
}
|
|
13310
|
+
const prefix = VARIABLE_SET_RESERVED_PREFIXES.find((candidate) => name.startsWith(candidate));
|
|
13311
|
+
return prefix ? { kind: "prefix", value: prefix } : null;
|
|
13312
|
+
}
|
|
13368
13313
|
function withVariableSetIdAlias(shape, options = {}) {
|
|
13369
13314
|
return z30.preprocess(
|
|
13370
13315
|
(input) => {
|
|
@@ -13949,15 +13894,16 @@ function scheduledTaskBoundedString(maxBytes, label) {
|
|
|
13949
13894
|
}
|
|
13950
13895
|
});
|
|
13951
13896
|
}
|
|
13952
|
-
var ScheduledTaskNameInput = /* @__PURE__ */ scheduledTaskBoundedString(
|
|
13953
|
-
SCHEDULED_TASK_NAME_MAX_BYTES,
|
|
13954
|
-
"scheduled task name"
|
|
13955
|
-
);
|
|
13897
|
+
var ScheduledTaskNameInput = /* @__PURE__ */ scheduledTaskBoundedString(SCHEDULED_TASK_NAME_MAX_BYTES, "scheduled task name");
|
|
13956
13898
|
var ScheduledTaskMetadataInput = /* @__PURE__ */ scheduledTaskBoundedJsonObject(
|
|
13957
13899
|
SCHEDULED_TASK_METADATA_MAX_BYTES,
|
|
13958
13900
|
"scheduled task metadata"
|
|
13959
13901
|
);
|
|
13960
13902
|
function scheduledTaskAgentConfigShape(bounded) {
|
|
13903
|
+
const machineTarget = z30.object({
|
|
13904
|
+
targetSandboxId: z30.string().uuid(),
|
|
13905
|
+
workingDir: bounded ? z30.string().trim().min(1).max(4096).optional() : z30.string().min(1).optional()
|
|
13906
|
+
}).strict();
|
|
13961
13907
|
return {
|
|
13962
13908
|
prompt: bounded ? scheduledTaskBoundedString(SCHEDULED_TASK_PROMPT_MAX_BYTES, "scheduled task prompt") : z30.string().min(1),
|
|
13963
13909
|
resources: bounded ? z30.array(ResourceRef).max(SCHEDULED_TASK_RESOURCE_MAX_COUNT).default([]) : z30.array(ResourceRef).default([]),
|
|
@@ -13970,6 +13916,10 @@ function scheduledTaskAgentConfigShape(bounded) {
|
|
|
13970
13916
|
model: bounded ? scheduledTaskBoundedString(512, "scheduled task model").optional() : z30.string().min(1).optional(),
|
|
13971
13917
|
reasoningEffort: ReasoningEffort.optional(),
|
|
13972
13918
|
sandboxBackend: SandboxBackend.optional(),
|
|
13919
|
+
// Connected Machines are a concrete execution target, not a generic
|
|
13920
|
+
// sandbox backend. Persist the exact machine + optional cwd so every
|
|
13921
|
+
// generated session can seed its active route before its first turn.
|
|
13922
|
+
machineTarget: machineTarget.optional(),
|
|
13973
13923
|
goal: GoalSpec.optional(),
|
|
13974
13924
|
// Incident telemetry is the only special execution class. Omission keeps
|
|
13975
13925
|
// every existing task on the byte-compatible ordinary dispatch path.
|
|
@@ -13998,6 +13948,20 @@ function refineScheduledTaskAgentConfig(value, context) {
|
|
|
13998
13948
|
}
|
|
13999
13949
|
var ScheduledTaskAgentConfig = /* @__PURE__ */ z30.object(scheduledTaskAgentConfigShape(false)).superRefine(refineScheduledTaskAgentConfig);
|
|
14000
13950
|
var ScheduledTaskAgentConfigInput = /* @__PURE__ */ z30.object(scheduledTaskAgentConfigShape(true)).superRefine((value, context) => {
|
|
13951
|
+
if (value.machineTarget && value.sandboxBackend !== void 0) {
|
|
13952
|
+
context.addIssue({
|
|
13953
|
+
code: "custom",
|
|
13954
|
+
path: ["machineTarget"],
|
|
13955
|
+
message: "machineTarget cannot be combined with sandboxBackend"
|
|
13956
|
+
});
|
|
13957
|
+
}
|
|
13958
|
+
if (value.sandboxBackend === "selfhosted") {
|
|
13959
|
+
context.addIssue({
|
|
13960
|
+
code: "custom",
|
|
13961
|
+
path: ["sandboxBackend"],
|
|
13962
|
+
message: "selfhosted scheduled tasks require machineTarget"
|
|
13963
|
+
});
|
|
13964
|
+
}
|
|
14001
13965
|
if (scheduledTaskJsonUtf8Bytes(value) > SCHEDULED_TASK_AGENT_CONFIG_MAX_BYTES) {
|
|
14002
13966
|
context.addIssue({
|
|
14003
13967
|
code: "custom",
|
|
@@ -14051,6 +14015,10 @@ var ScheduledTaskRunAcceptedExecution = /* @__PURE__ */ z30.object({
|
|
|
14051
14015
|
resolvedModel: z30.string().min(1),
|
|
14052
14016
|
resolvedReasoningEffort: ReasoningEffort,
|
|
14053
14017
|
resolvedLatencyMode: LatencyMode,
|
|
14018
|
+
/** Secret-safe TurnExecutionPolicyV1 accepted with this occurrence. Kept
|
|
14019
|
+
* structurally open here because the canonical policy schema is declared
|
|
14020
|
+
* later in this package; consumers must parse it with TurnExecutionPolicyV1. */
|
|
14021
|
+
turnExecutionPolicy: z30.unknown().optional(),
|
|
14054
14022
|
resolvedSandboxBackend: SandboxBackend,
|
|
14055
14023
|
resolvedSandboxOs: SandboxOs,
|
|
14056
14024
|
resolvedTools: z30.array(ToolRef).max(SCHEDULED_TASK_TOOL_MAX_COUNT),
|
|
@@ -14250,6 +14218,13 @@ var CreateAgentScheduledTaskRequest = /* @__PURE__ */ withVariableSetIdAlias({
|
|
|
14250
14218
|
message: "agentConfig.goal cannot be used with an existing-session target"
|
|
14251
14219
|
});
|
|
14252
14220
|
}
|
|
14221
|
+
if (value.runMode === "existing_session" && value.agentConfig.machineTarget) {
|
|
14222
|
+
context.addIssue({
|
|
14223
|
+
code: "custom",
|
|
14224
|
+
path: ["agentConfig", "machineTarget"],
|
|
14225
|
+
message: "machineTarget cannot be used with an existing-session target"
|
|
14226
|
+
});
|
|
14227
|
+
}
|
|
14253
14228
|
});
|
|
14254
14229
|
var CreateKnowledgeSourceSyncScheduledTaskRequest = /* @__PURE__ */ z30.object({
|
|
14255
14230
|
name: z30.string().min(1),
|
|
@@ -14315,6 +14290,13 @@ var UpdateScheduledTaskRequest = /* @__PURE__ */ withVariableSetIdAlias({
|
|
|
14315
14290
|
message: "agentConfig.goal cannot be used with an existing-session target"
|
|
14316
14291
|
});
|
|
14317
14292
|
}
|
|
14293
|
+
if (value.agentConfig?.machineTarget && (value.runMode === "existing_session" || Boolean(value.targetSessionId))) {
|
|
14294
|
+
context.addIssue({
|
|
14295
|
+
code: "custom",
|
|
14296
|
+
path: ["agentConfig", "machineTarget"],
|
|
14297
|
+
message: "machineTarget cannot be used with an existing-session target"
|
|
14298
|
+
});
|
|
14299
|
+
}
|
|
14318
14300
|
});
|
|
14319
14301
|
var TriggerScheduledTaskRequest = z30.object({
|
|
14320
14302
|
triggerId: z30.string().min(1).max(128).optional()
|
|
@@ -15271,6 +15253,10 @@ function compareDescending(left, right) {
|
|
|
15271
15253
|
return left > right ? -1 : 1;
|
|
15272
15254
|
}
|
|
15273
15255
|
var ConnectionCredentialBundle = z30.record(z30.string(), z30.unknown());
|
|
15256
|
+
var VERCEL_AI_GATEWAY_CREDENTIAL_OPERATION_ID_METADATA_KEY = "vercelAiGatewayCredentialOperationId";
|
|
15257
|
+
var VERCEL_AI_GATEWAY_CREDENTIAL_OPERATION_DIGEST_METADATA_KEY = "vercelAiGatewayCredentialOperationDigest";
|
|
15258
|
+
var OPENROUTER_CREDENTIAL_OPERATION_ID_METADATA_KEY = "openRouterCredentialOperationId";
|
|
15259
|
+
var OPENROUTER_CREDENTIAL_OPERATION_DIGEST_METADATA_KEY = "openRouterCredentialOperationDigest";
|
|
15274
15260
|
var CreateConnectionRequest = z30.object({
|
|
15275
15261
|
providerDomain: z30.string().min(1),
|
|
15276
15262
|
kind: ConnectionKind,
|
|
@@ -15280,7 +15266,8 @@ var CreateConnectionRequest = z30.object({
|
|
|
15280
15266
|
credential: ConnectionCredentialBundle,
|
|
15281
15267
|
grantedScopes: z30.array(z30.string().min(1)).default([]),
|
|
15282
15268
|
expiresAt: z30.string().datetime({ offset: true }).nullable().optional(),
|
|
15283
|
-
metadata: z30.record(z30.string(), z30.unknown()).default({})
|
|
15269
|
+
metadata: z30.record(z30.string(), z30.unknown()).default({}),
|
|
15270
|
+
operationId: z30.string().uuid().optional()
|
|
15284
15271
|
});
|
|
15285
15272
|
var OpenGeniSlackBotInstallRequest = z30.object({
|
|
15286
15273
|
connectionId: z30.string().uuid().optional()
|
|
@@ -15321,7 +15308,9 @@ var UpdateConnectionRequest = z30.object({
|
|
|
15321
15308
|
credential: ConnectionCredentialBundle.optional(),
|
|
15322
15309
|
grantedScopes: z30.array(z30.string().min(1)).optional(),
|
|
15323
15310
|
expiresAt: z30.string().datetime({ offset: true }).nullable().optional(),
|
|
15324
|
-
metadata: z30.record(z30.string(), z30.unknown()).optional()
|
|
15311
|
+
metadata: z30.record(z30.string(), z30.unknown()).optional(),
|
|
15312
|
+
expectedVersion: z30.number().int().positive().optional(),
|
|
15313
|
+
operationId: z30.string().uuid().optional()
|
|
15325
15314
|
});
|
|
15326
15315
|
var ConnectionResponse = z30.object({
|
|
15327
15316
|
connection: ConnectionMetadata
|
|
@@ -16245,8 +16234,11 @@ var Session = z30.object({
|
|
|
16245
16234
|
queuedDescendants: z30.number().int().nonnegative(),
|
|
16246
16235
|
attentionDescendants: z30.number().int().nonnegative(),
|
|
16247
16236
|
pausedDescendants: z30.number().int().nonnegative(),
|
|
16237
|
+
/** Historical failed lifecycle states, including already-reviewed failures. */
|
|
16248
16238
|
failedDescendants: z30.number().int().nonnegative(),
|
|
16249
16239
|
unreadDescendants: z30.number().int().nonnegative().optional(),
|
|
16240
|
+
/** Failed descendants whose latest durable event this viewer has not acknowledged. */
|
|
16241
|
+
unreadFailedDescendants: z30.number().int().nonnegative().optional(),
|
|
16250
16242
|
activelyWorkingDescendants: z30.number().int().nonnegative().optional(),
|
|
16251
16243
|
/**
|
|
16252
16244
|
* Earliest moment one of the counted `attentionDescendants` entered
|
|
@@ -18368,7 +18360,8 @@ var ClientAuthConfig = z30.discriminatedUnion("mode", [
|
|
|
18368
18360
|
z30.object({
|
|
18369
18361
|
mode: z30.literal("managedSession"),
|
|
18370
18362
|
session: z30.literal("cookie"),
|
|
18371
|
-
emailVerificationRequired: z30.boolean().default(true)
|
|
18363
|
+
emailVerificationRequired: z30.boolean().default(true),
|
|
18364
|
+
socialProviders: z30.array(z30.enum(["google", "github"])).max(2).default([])
|
|
18372
18365
|
})
|
|
18373
18366
|
]);
|
|
18374
18367
|
var CapabilityUnavailableReason = z30.enum([
|
|
@@ -18461,10 +18454,10 @@ var SessionCapabilities = z30.object({
|
|
|
18461
18454
|
codecs: z30.array(z30.enum(["h264-mp4", "vp9-webm"])),
|
|
18462
18455
|
reason: CapabilityUnavailableReason.nullable()
|
|
18463
18456
|
}),
|
|
18464
|
-
//
|
|
18465
|
-
//
|
|
18466
|
-
//
|
|
18467
|
-
//
|
|
18457
|
+
// Deprecated compatibility cell for clients that predate managed
|
|
18458
|
+
// ComputerSession interaction tools. Newly negotiated documents report this
|
|
18459
|
+
// unavailable/read-only with `disabled_by_policy`; the shape remains so older
|
|
18460
|
+
// clients and persisted payloads still parse.
|
|
18468
18461
|
ComputerUse: z30.object({
|
|
18469
18462
|
available: z30.boolean(),
|
|
18470
18463
|
readOnly: z30.boolean(),
|
|
@@ -18879,9 +18872,7 @@ var MachineMetricsSeriesResponse = z30.object({
|
|
|
18879
18872
|
function defineModelContractSchema(factory) {
|
|
18880
18873
|
return factory();
|
|
18881
18874
|
}
|
|
18882
|
-
var ModelCapabilitySupportV1 = /* @__PURE__ */ defineModelContractSchema(
|
|
18883
|
-
() => z30.enum(["supported", "unsupported", "unknown"])
|
|
18884
|
-
);
|
|
18875
|
+
var ModelCapabilitySupportV1 = /* @__PURE__ */ defineModelContractSchema(() => z30.enum(["supported", "unsupported", "unknown"]));
|
|
18885
18876
|
var ModelCapabilityStateV1 = /* @__PURE__ */ defineModelContractSchema(
|
|
18886
18877
|
() => z30.object({
|
|
18887
18878
|
upstream: ModelCapabilitySupportV1,
|
|
@@ -18952,6 +18943,9 @@ var ModelBillingAttributionV1 = /* @__PURE__ */ defineModelContractSchema(
|
|
|
18952
18943
|
metering: z30.enum(["opengeni_credits", "external"])
|
|
18953
18944
|
}).strict()
|
|
18954
18945
|
);
|
|
18946
|
+
var ModelCostClassV1 = /* @__PURE__ */ defineModelContractSchema(
|
|
18947
|
+
() => z30.enum(["free", "credits", "subscription", "workspace"])
|
|
18948
|
+
);
|
|
18955
18949
|
var TURN_EXECUTION_POLICY_METADATA_KEY = "turnExecutionPolicyV1";
|
|
18956
18950
|
var TurnExecutionModelSourceV1 = /* @__PURE__ */ defineModelContractSchema(
|
|
18957
18951
|
() => z30.enum(["explicit", "session", "deployment", "continuation"])
|
|
@@ -19073,7 +19067,7 @@ var ClientModel = /* @__PURE__ */ defineModelContractSchema(
|
|
|
19073
19067
|
// provider id
|
|
19074
19068
|
providerLabel: z30.string(),
|
|
19075
19069
|
api: z30.enum(["responses", "chat"]),
|
|
19076
|
-
source: z30.enum(["opengeni", "codex", "supergrok", "workspace_gateway"]).optional(),
|
|
19070
|
+
source: z30.enum(["opengeni", "codex", "supergrok", "workspace_gateway", "openrouter"]).optional(),
|
|
19077
19071
|
contextWindowTokens: z30.number().int().positive().optional(),
|
|
19078
19072
|
// Additive normalized definition metadata. Optional so older server payloads
|
|
19079
19073
|
// remain parseable; current servers project the complete V1 set.
|
|
@@ -19091,6 +19085,7 @@ var ClientModel = /* @__PURE__ */ defineModelContractSchema(
|
|
|
19091
19085
|
}).optional(),
|
|
19092
19086
|
credentialSource: ModelCredentialSourceV1.optional(),
|
|
19093
19087
|
billing: ModelBillingAttributionV1.optional(),
|
|
19088
|
+
cost: ModelCostClassV1.optional(),
|
|
19094
19089
|
capabilities: ModelCapabilitiesV1.optional(),
|
|
19095
19090
|
pricing: ModelPricingScheduleV1.optional(),
|
|
19096
19091
|
definitionVersion: z30.string().regex(/^sha256:[a-f0-9]{64}$/u).optional()
|
|
@@ -19186,6 +19181,9 @@ var ClientConfig = /* @__PURE__ */ defineModelContractSchema(
|
|
|
19186
19181
|
models: z30.array(ClientModel).default([]),
|
|
19187
19182
|
defaultReasoningEffort: ReasoningEffort,
|
|
19188
19183
|
allowedReasoningEfforts: z30.array(ReasoningEffort).min(1),
|
|
19184
|
+
// Client-safe execution default. The schedule editor uses this to avoid
|
|
19185
|
+
// presenting a targetless "managed" choice on self-hosted deployments.
|
|
19186
|
+
defaultSandboxBackend: SandboxBackend.default("modal"),
|
|
19189
19187
|
mcpServers: z30.array(
|
|
19190
19188
|
z30.object({
|
|
19191
19189
|
id: z30.string(),
|
|
@@ -19804,10 +19802,6 @@ export {
|
|
|
19804
19802
|
SANDBOX_FILE_ARTIFACT_MAX_BYTES,
|
|
19805
19803
|
PublishSandboxFileArtifactRequest,
|
|
19806
19804
|
SandboxFileArtifactReceipt,
|
|
19807
|
-
SESSION_TITLE_MAX_CHARACTERS,
|
|
19808
|
-
AUTOMATIC_SESSION_TITLE_MAX_GRAPHEMES,
|
|
19809
|
-
AUTOMATIC_SESSION_TITLE_FALLBACK,
|
|
19810
|
-
normalizeAutomaticSessionTitle,
|
|
19811
19805
|
WORK_CLAIM_NAMESPACE_MAX_BYTES,
|
|
19812
19806
|
WORK_CLAIM_CANONICAL_KEY_MAX_BYTES,
|
|
19813
19807
|
WORK_CLAIM_DISPLAY_LABEL_MAX_BYTES,
|
|
@@ -19903,6 +19897,8 @@ export {
|
|
|
19903
19897
|
AGENT_AUTHORED_PREFERENCE_CONTENT_TOO_LONG_MESSAGE,
|
|
19904
19898
|
AGENT_AUTHORED_COMPANY_PROFILE_TOO_LONG_MESSAGE,
|
|
19905
19899
|
AGENT_AUTHORED_REMEMBER_CONTENT_TOO_LONG_MESSAGE,
|
|
19900
|
+
AGENT_AUTHORED_INSTRUCTION_POLICY_STYLE,
|
|
19901
|
+
AGENT_AUTHORED_SKILL_STYLE,
|
|
19906
19902
|
AGENT_AUTHORED_DURABLE_TEXT_STYLE,
|
|
19907
19903
|
agentAuthoredDurableTextTooLongMessage,
|
|
19908
19904
|
COMPANY_PROFILE_SCALAR_MAX_CHARS,
|
|
@@ -19938,9 +19934,14 @@ export {
|
|
|
19938
19934
|
CompanyProfileMutationResponse,
|
|
19939
19935
|
COMPANY_PROFILE_AGENT_APPROVE_OPTION,
|
|
19940
19936
|
COMPANY_PROFILE_AGENT_REJECT_OPTION,
|
|
19937
|
+
CompanyProfileAgentPolicyMode,
|
|
19938
|
+
CompanyProfileAgentPolicy,
|
|
19939
|
+
UpdateCompanyProfileAgentPolicyRequest,
|
|
19941
19940
|
CompanyProfileAgentAttempt,
|
|
19942
19941
|
CompanyProfileAgentProposalRequest,
|
|
19943
19942
|
CompanyProfileAgentHumanInputPrompt,
|
|
19943
|
+
CompanyProfileAgentReviewRequiredReceipt,
|
|
19944
|
+
CompanyProfileAgentAutomaticActivationReceipt,
|
|
19944
19945
|
CompanyProfileAgentProposalReceipt,
|
|
19945
19946
|
CompanyProfileAgentConfirmRequest,
|
|
19946
19947
|
CompanyProfileAgentConfirmationReceipt,
|
|
@@ -20312,6 +20313,15 @@ export {
|
|
|
20312
20313
|
UpdateWorkspaceSettingsRequest,
|
|
20313
20314
|
SetWorkspaceDefaultRigRequest,
|
|
20314
20315
|
UpdateWorkspaceModelPolicyRequest,
|
|
20316
|
+
WORKSPACE_GATEWAY_CUSTOM_MODEL_UPSTREAM_ID_MAX_LENGTH,
|
|
20317
|
+
CreateWorkspaceGatewayCustomModelRequest,
|
|
20318
|
+
DeleteWorkspaceGatewayCustomModelRequest,
|
|
20319
|
+
WorkspaceGatewayCustomModel,
|
|
20320
|
+
WorkspaceGatewayCustomModelsResponse,
|
|
20321
|
+
CreateWorkspaceOpenRouterCustomModelRequest,
|
|
20322
|
+
DeleteWorkspaceOpenRouterCustomModelRequest,
|
|
20323
|
+
WorkspaceOpenRouterCustomModel,
|
|
20324
|
+
WorkspaceOpenRouterCustomModelsResponse,
|
|
20315
20325
|
UNATTRIBUTED_LEGACY_INITIATOR_SUBJECT_ID,
|
|
20316
20326
|
ServiceTurnInitiator,
|
|
20317
20327
|
TurnInitiatorContext,
|
|
@@ -20337,12 +20347,17 @@ export {
|
|
|
20337
20347
|
signRelayToken,
|
|
20338
20348
|
verifyRelayToken,
|
|
20339
20349
|
CreateWorkspaceRequest,
|
|
20350
|
+
EnsureWorkspaceRequest,
|
|
20351
|
+
EnsureWorkspaceResponse,
|
|
20340
20352
|
UpdateWorkspaceRequest,
|
|
20341
20353
|
ApiKey,
|
|
20342
20354
|
CreateApiKeyRequest,
|
|
20343
20355
|
CreateApiKeyResponse,
|
|
20356
|
+
CreateOrganizationApiKeyRequest,
|
|
20344
20357
|
WorkspaceMember,
|
|
20345
20358
|
ListWorkspaceMembersResponse,
|
|
20359
|
+
WorkspaceMemberCandidate,
|
|
20360
|
+
ListWorkspaceMemberCandidatesResponse,
|
|
20346
20361
|
AddWorkspaceMemberRequest,
|
|
20347
20362
|
UpdateWorkspaceMemberRequest,
|
|
20348
20363
|
SlackUserLinkAccessRequestStatus,
|
|
@@ -20654,8 +20669,12 @@ export {
|
|
|
20654
20669
|
SessionPendingInputPreview,
|
|
20655
20670
|
SessionQueueSnapshot,
|
|
20656
20671
|
renderSessionSystemUpdateBatch,
|
|
20672
|
+
SCHEDULED_OCCURRENCE_TASK_LABEL,
|
|
20657
20673
|
sessionSystemUpdateBatchHistoryItem,
|
|
20658
20674
|
VariableSetVariableName,
|
|
20675
|
+
VARIABLE_SET_RESERVED_EXACT_NAMES,
|
|
20676
|
+
VARIABLE_SET_RESERVED_PREFIXES,
|
|
20677
|
+
variableSetVariableNameReservation,
|
|
20659
20678
|
VariableSetVariableMetadata,
|
|
20660
20679
|
WorkspaceEnvironmentVariableMetadata,
|
|
20661
20680
|
VariableSetSecret,
|
|
@@ -20824,6 +20843,10 @@ export {
|
|
|
20824
20843
|
comparePersonalSlackCanonicalConnections,
|
|
20825
20844
|
selectCanonicalPersonalSlackConnection,
|
|
20826
20845
|
ConnectionCredentialBundle,
|
|
20846
|
+
VERCEL_AI_GATEWAY_CREDENTIAL_OPERATION_ID_METADATA_KEY,
|
|
20847
|
+
VERCEL_AI_GATEWAY_CREDENTIAL_OPERATION_DIGEST_METADATA_KEY,
|
|
20848
|
+
OPENROUTER_CREDENTIAL_OPERATION_ID_METADATA_KEY,
|
|
20849
|
+
OPENROUTER_CREDENTIAL_OPERATION_DIGEST_METADATA_KEY,
|
|
20827
20850
|
CreateConnectionRequest,
|
|
20828
20851
|
OpenGeniSlackBotInstallRequest,
|
|
20829
20852
|
OpenGeniSlackBotInstallStart,
|
|
@@ -21111,6 +21134,7 @@ export {
|
|
|
21111
21134
|
ModelCapabilitiesV1,
|
|
21112
21135
|
ModelCredentialSourceV1,
|
|
21113
21136
|
ModelBillingAttributionV1,
|
|
21137
|
+
ModelCostClassV1,
|
|
21114
21138
|
TURN_EXECUTION_POLICY_METADATA_KEY,
|
|
21115
21139
|
TurnExecutionModelSourceV1,
|
|
21116
21140
|
TurnExecutionReasoningSourceV1,
|
|
@@ -21132,4 +21156,4 @@ export {
|
|
|
21132
21156
|
ClientConfig,
|
|
21133
21157
|
evaluateWorkspaceModelPolicy
|
|
21134
21158
|
};
|
|
21135
|
-
//# sourceMappingURL=chunk-
|
|
21159
|
+
//# sourceMappingURL=chunk-UGGTRQNU.js.map
|