@amaster.ai/employee-runtime-connector 0.1.1-beta.287 → 0.1.1-beta.288
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.
|
@@ -5951,6 +5951,7 @@ var ISSUE_THREAD_INTERACTION_KINDS = [
|
|
|
5951
5951
|
var ISSUE_THREAD_INTERACTION_SETTLEMENT_PURPOSE_CODES = [
|
|
5952
5952
|
"request_required_inputs",
|
|
5953
5953
|
"clarify_required_scope",
|
|
5954
|
+
"business_data_source_selection",
|
|
5954
5955
|
"resolve_staffing_gap",
|
|
5955
5956
|
"review_suggested_tasks",
|
|
5956
5957
|
"choose_task_disposition",
|
|
@@ -10113,7 +10114,7 @@ var scheduleIssueRecoveryMonitorSchema = external_exports.object({
|
|
|
10113
10114
|
nextCheckAt: external_exports.string().datetime()
|
|
10114
10115
|
}).strict();
|
|
10115
10116
|
var issueRequestDepthInputSchema = external_exports.number().int().nonnegative().transform((value) => clampIssueRequestDepth(value));
|
|
10116
|
-
var estimatedLaborHoursSchema = external_exports.number().finite().
|
|
10117
|
+
var estimatedLaborHoursSchema = external_exports.number().finite().positive().max(1e6);
|
|
10117
10118
|
var issueDateSchema = external_exports.string().refine((value) => {
|
|
10118
10119
|
const match = /^(\d{4})-(\d{2})-(\d{2})$/.exec(value);
|
|
10119
10120
|
if (!match) return false;
|
|
@@ -10213,13 +10214,22 @@ function addExactlyOneTaskDirectionIssue(value, ctx) {
|
|
|
10213
10214
|
if (count2 === 1) return;
|
|
10214
10215
|
ctx.addIssue({
|
|
10215
10216
|
code: external_exports.ZodIssueCode.custom,
|
|
10216
|
-
path: ["labelIds"],
|
|
10217
|
+
path: value.labels?.length && !value.labelIds?.length ? ["labels"] : ["labelIds"],
|
|
10217
10218
|
message: count2 === 0 ? "Task direction is required" : "Exactly one task direction is required",
|
|
10218
10219
|
params: {
|
|
10219
10220
|
code: count2 === 0 ? "task_direction_required" : "task_direction_exactly_one_required"
|
|
10220
10221
|
}
|
|
10221
10222
|
});
|
|
10222
10223
|
}
|
|
10224
|
+
function addRequiredEstimatedLaborIssue(value, ctx) {
|
|
10225
|
+
if (value.estimatedLaborHours !== void 0 && value.estimatedLaborHours !== null) return;
|
|
10226
|
+
ctx.addIssue({
|
|
10227
|
+
code: external_exports.ZodIssueCode.custom,
|
|
10228
|
+
path: ["estimatedLaborHours"],
|
|
10229
|
+
message: "Estimated labor hours are required",
|
|
10230
|
+
params: { code: "estimated_labor_hours_required" }
|
|
10231
|
+
});
|
|
10232
|
+
}
|
|
10223
10233
|
var createIssueInputSchema = createIssueBaseSchema.extend({
|
|
10224
10234
|
status: createIssueBaseSchema.shape.status.optional(),
|
|
10225
10235
|
labels: createIssueLabelNamesSchema.optional()
|
|
@@ -10241,10 +10251,19 @@ var createModelIssueSchema = createIssueSchema.superRefine((value, ctx) => {
|
|
|
10241
10251
|
if (value.prerequisiteSlots !== void 0 || value.prerequisiteChecks !== void 0) {
|
|
10242
10252
|
ctx.addIssue({ code: external_exports.ZodIssueCode.custom, path: ["prerequisiteSlots"], message: "Model creation cannot declare cross-Issue prerequisite authority" });
|
|
10243
10253
|
}
|
|
10254
|
+
const mirrorxAgentSession = value.creationProfile === MIRRORX_AGENT_SESSION_CREATION_PROFILE;
|
|
10244
10255
|
const systemWatchdogFollowUp = value.watchdogDiscovery?.kind === "product_bug";
|
|
10245
|
-
if (
|
|
10246
|
-
|
|
10256
|
+
if (mirrorxAgentSession || systemWatchdogFollowUp) return;
|
|
10257
|
+
if (!value.parentId && value.taskIntent !== "business") {
|
|
10258
|
+
ctx.addIssue({
|
|
10259
|
+
code: external_exports.ZodIssueCode.custom,
|
|
10260
|
+
path: ["taskIntent"],
|
|
10261
|
+
message: "Model-created root tasks must use business intent",
|
|
10262
|
+
params: { code: "model_business_task_intent_required" }
|
|
10263
|
+
});
|
|
10247
10264
|
}
|
|
10265
|
+
addExactlyOneTaskDirectionIssue(value, ctx);
|
|
10266
|
+
addRequiredEstimatedLaborIssue(value, ctx);
|
|
10248
10267
|
});
|
|
10249
10268
|
var upsertIssueWatchdogSchema = external_exports.object({
|
|
10250
10269
|
agentId: external_exports.string().uuid(),
|
|
@@ -10274,9 +10293,10 @@ var createChildIssueSchema = withCreateIssueStatusDefault(createIssueBaseSchema.
|
|
|
10274
10293
|
inputWorkProductIds: external_exports.array(external_exports.string().uuid()).max(50).optional(),
|
|
10275
10294
|
labels: createIssueLabelNamesSchema.optional()
|
|
10276
10295
|
}));
|
|
10277
|
-
var createModelChildIssueSchema = createChildIssueSchema.superRefine(
|
|
10278
|
-
addExactlyOneTaskDirectionIssue
|
|
10279
|
-
);
|
|
10296
|
+
var createModelChildIssueSchema = createChildIssueSchema.superRefine((value, ctx) => {
|
|
10297
|
+
addExactlyOneTaskDirectionIssue(value, ctx);
|
|
10298
|
+
addRequiredEstimatedLaborIssue(value, ctx);
|
|
10299
|
+
});
|
|
10280
10300
|
var createAcceptedPlanDecompositionSchema = external_exports.object({
|
|
10281
10301
|
acceptedPlanRevisionId: external_exports.string().uuid(),
|
|
10282
10302
|
children: external_exports.array(createModelChildIssueSchema).min(1).max(25)
|
|
@@ -10482,7 +10502,7 @@ var suggestedTaskDraftSchema = external_exports.object({
|
|
|
10482
10502
|
title: external_exports.string().trim().min(1).max(240),
|
|
10483
10503
|
description: multilineTextSchema.pipe(external_exports.string().trim().max(2e4)).nullable().optional(),
|
|
10484
10504
|
delegation: issueDelegationInputSchema,
|
|
10485
|
-
estimatedLaborHours: estimatedLaborHoursSchema.
|
|
10505
|
+
estimatedLaborHours: estimatedLaborHoursSchema.nullable().optional(),
|
|
10486
10506
|
priority: external_exports.enum(ISSUE_PRIORITIES).nullable().optional(),
|
|
10487
10507
|
workMode: external_exports.enum(ISSUE_WORK_MODES).nullable().optional(),
|
|
10488
10508
|
assigneeAgentId: external_exports.string().uuid().nullable().optional(),
|
|
@@ -10560,6 +10580,28 @@ var suggestTasksPayloadSchema = external_exports.object({
|
|
|
10560
10580
|
seenClientKeys.add(task.clientKey);
|
|
10561
10581
|
}
|
|
10562
10582
|
});
|
|
10583
|
+
var modelSuggestedTaskDraftSchema = suggestedTaskDraftSchema.superRefine((value, ctx) => {
|
|
10584
|
+
addExactlyOneTaskDirectionIssue(value, ctx);
|
|
10585
|
+
addRequiredEstimatedLaborIssue(value, ctx);
|
|
10586
|
+
});
|
|
10587
|
+
var modelSuggestTasksPayloadSchema = external_exports.object({
|
|
10588
|
+
version: external_exports.literal(1),
|
|
10589
|
+
defaultParentId: external_exports.string().uuid().nullable().optional(),
|
|
10590
|
+
tasks: external_exports.array(modelSuggestedTaskDraftSchema).min(1).max(50)
|
|
10591
|
+
}).superRefine((value, ctx) => {
|
|
10592
|
+
const seenClientKeys = /* @__PURE__ */ new Set();
|
|
10593
|
+
for (const [index, task] of value.tasks.entries()) {
|
|
10594
|
+
if (seenClientKeys.has(task.clientKey)) {
|
|
10595
|
+
ctx.addIssue({
|
|
10596
|
+
code: external_exports.ZodIssueCode.custom,
|
|
10597
|
+
message: "clientKey must be unique within one interaction",
|
|
10598
|
+
path: ["tasks", index, "clientKey"]
|
|
10599
|
+
});
|
|
10600
|
+
continue;
|
|
10601
|
+
}
|
|
10602
|
+
seenClientKeys.add(task.clientKey);
|
|
10603
|
+
}
|
|
10604
|
+
});
|
|
10563
10605
|
var suggestTasksResultCreatedTaskSchema = external_exports.object({
|
|
10564
10606
|
clientKey: external_exports.string().trim().min(1).max(120),
|
|
10565
10607
|
workKey: external_exports.string().trim().min(1).max(120).nullable().optional(),
|
|
@@ -14566,6 +14608,25 @@ var routineTemplateAdoptionBatchSchema = external_exports.object({
|
|
|
14566
14608
|
afterCompanyId: external_exports.string().uuid().optional().nullable(),
|
|
14567
14609
|
limit: external_exports.number().int().min(1).max(25).optional()
|
|
14568
14610
|
}).strict();
|
|
14611
|
+
var routineTaskProfileMigrationPreviewSchema = external_exports.object({}).strict();
|
|
14612
|
+
var routineTaskProfileMigrationApplySchema = external_exports.object({
|
|
14613
|
+
operationKey: external_exports.string().trim().min(1).max(200),
|
|
14614
|
+
confirmation: external_exports.literal("APPLY_ROUTINE_TASK_PROFILES"),
|
|
14615
|
+
assignments: external_exports.array(external_exports.object({
|
|
14616
|
+
routineId: external_exports.string().uuid(),
|
|
14617
|
+
taskDirectionLabelId: external_exports.string().uuid(),
|
|
14618
|
+
estimatedLaborHours: external_exports.number().finite().positive().max(1e6),
|
|
14619
|
+
confirmedCanonicalKey: external_exports.string().trim().min(1).max(100).optional()
|
|
14620
|
+
}).strict()).min(1).max(500)
|
|
14621
|
+
}).strict().superRefine((value, ctx) => {
|
|
14622
|
+
if (new Set(value.assignments.map((item) => item.routineId)).size !== value.assignments.length) {
|
|
14623
|
+
ctx.addIssue({
|
|
14624
|
+
code: external_exports.ZodIssueCode.custom,
|
|
14625
|
+
path: ["assignments"],
|
|
14626
|
+
message: "Routine IDs must be unique"
|
|
14627
|
+
});
|
|
14628
|
+
}
|
|
14629
|
+
});
|
|
14569
14630
|
var routineRevisionSnapshotRoutineV1Schema = external_exports.object({
|
|
14570
14631
|
id: external_exports.string().uuid(),
|
|
14571
14632
|
companyId: external_exports.string().uuid(),
|
|
@@ -33709,7 +33770,7 @@ function assertRequiredTaskAttachmentMaterialized(input, materialized) {
|
|
|
33709
33770
|
}
|
|
33710
33771
|
|
|
33711
33772
|
// src/amaster-runtime-daemon.mjs
|
|
33712
|
-
var CONNECTOR_VERSION = "0.1.1-beta.
|
|
33773
|
+
var CONNECTOR_VERSION = "0.1.1-beta.288";
|
|
33713
33774
|
var CONNECTOR_CONTRACT_VERSION = "2026-06-04.v1";
|
|
33714
33775
|
var daemonRequire = createRequire(import.meta.url);
|
|
33715
33776
|
var MAX_CHECKPOINT_BYTES = 20 * 1024 * 1024;
|
package/dist/amaster-runtime.mjs
CHANGED
|
@@ -7,7 +7,7 @@ import { homedir, hostname } from "node:os";
|
|
|
7
7
|
import { fileURLToPath } from "node:url";
|
|
8
8
|
import { BUILD_SUPPORTED_CAPABILITIES } from "./amaster-runtime-daemon/capability-registry.mjs";
|
|
9
9
|
|
|
10
|
-
const CONNECTOR_VERSION = "0.1.1-beta.
|
|
10
|
+
const CONNECTOR_VERSION = "0.1.1-beta.288";
|
|
11
11
|
|
|
12
12
|
const CONFIG_KEY_MAP = new Map([
|
|
13
13
|
["server_url", "AMASTER_EMPLOYEE_SERVER_URL"],
|