@amaster.ai/employee-runtime-connector 0.1.1-beta.233 → 0.1.1-beta.235
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.
|
@@ -4554,7 +4554,7 @@ var updateMirrorxAgentSessionPreferenceSchema = external_exports.object({
|
|
|
4554
4554
|
(value) => value.groupId !== void 0 || value.pinned !== void 0 || value.archived !== void 0,
|
|
4555
4555
|
{ message: "At least one session preference field is required" }
|
|
4556
4556
|
);
|
|
4557
|
-
var mirrorxAgentSessionSectionSchema = external_exports.enum(["pinned", "recent", "group", "archived"]);
|
|
4557
|
+
var mirrorxAgentSessionSectionSchema = external_exports.enum(["attention", "pinned", "recent", "group", "archived"]);
|
|
4558
4558
|
var mirrorxAgentSessionSectionQuerySchema = external_exports.object({
|
|
4559
4559
|
section: mirrorxAgentSessionSectionSchema,
|
|
4560
4560
|
groupId: external_exports.string().uuid().optional(),
|
|
@@ -4576,6 +4576,12 @@ var mirrorxAgentSessionSectionQuerySchema = external_exports.object({
|
|
|
4576
4576
|
});
|
|
4577
4577
|
}
|
|
4578
4578
|
});
|
|
4579
|
+
var MIRRORX_SESSION_RESULT_DEFAULT_LIMIT = 50;
|
|
4580
|
+
var MIRRORX_SESSION_RESULT_MAX_LIMIT = 100;
|
|
4581
|
+
var mirrorxSessionResultSummariesQuerySchema = external_exports.object({
|
|
4582
|
+
limit: external_exports.coerce.number().int().min(1).max(MIRRORX_SESSION_RESULT_MAX_LIMIT).default(MIRRORX_SESSION_RESULT_DEFAULT_LIMIT),
|
|
4583
|
+
cursor: external_exports.string().trim().min(1).max(2048).optional()
|
|
4584
|
+
});
|
|
4579
4585
|
var mirrorxSessionComposerControlSchema = external_exports.object({
|
|
4580
4586
|
stateVersion: external_exports.string().trim().min(1).max(200),
|
|
4581
4587
|
expectedRunId: external_exports.string().uuid()
|
|
@@ -7777,6 +7783,7 @@ function resolveMirrorxWorkKindPurpose(workKind) {
|
|
|
7777
7783
|
|
|
7778
7784
|
// ../shared/src/task-resource-input.ts
|
|
7779
7785
|
var ATTACHMENT_PREPARATION_VERSION = "attachment-preparation-v1";
|
|
7786
|
+
var ORIGINAL_ONLY_PARSER_VERSION = "original-only-v1";
|
|
7780
7787
|
var TASK_RESOURCE_INPUT_STATES = [
|
|
7781
7788
|
"declared",
|
|
7782
7789
|
"preparing",
|
|
@@ -7876,18 +7883,27 @@ var taskResourceInputSchema = external_exports.discriminatedUnion("kind", [
|
|
|
7876
7883
|
assetId: external_exports.string().uuid(),
|
|
7877
7884
|
byteSize: external_exports.number().int().nonnegative(),
|
|
7878
7885
|
sha256: sha256Schema4,
|
|
7886
|
+
parserVersion: external_exports.string().trim().min(1).max(120).nullable().optional(),
|
|
7879
7887
|
sidecarAssetId: external_exports.string().uuid().nullable().optional(),
|
|
7880
7888
|
preparationReceipt: attachmentPreparationReceiptSchema.nullable().optional()
|
|
7881
7889
|
}).strict()
|
|
7882
7890
|
]).superRefine((value, context) => {
|
|
7883
7891
|
if (value.kind !== "attachment") return;
|
|
7884
|
-
|
|
7892
|
+
const originalOnly = value.parserVersion === ORIGINAL_ONLY_PARSER_VERSION;
|
|
7893
|
+
if (value.state === "prepared" && !value.preparationReceipt && !originalOnly) {
|
|
7885
7894
|
context.addIssue({
|
|
7886
7895
|
code: external_exports.ZodIssueCode.custom,
|
|
7887
7896
|
path: ["preparationReceipt"],
|
|
7888
7897
|
message: "Prepared attachment input requires a complete preparation receipt"
|
|
7889
7898
|
});
|
|
7890
7899
|
}
|
|
7900
|
+
if (originalOnly && (value.preparationReceipt || value.sidecarAssetId)) {
|
|
7901
|
+
context.addIssue({
|
|
7902
|
+
code: external_exports.ZodIssueCode.custom,
|
|
7903
|
+
path: ["preparationReceipt"],
|
|
7904
|
+
message: "Original-only attachment input must not carry a preparation sidecar"
|
|
7905
|
+
});
|
|
7906
|
+
}
|
|
7891
7907
|
if (value.preparationReceipt && (value.preparationReceipt.originalSha256 !== value.sha256 || value.preparationReceipt.originalBytes !== value.byteSize)) {
|
|
7892
7908
|
context.addIssue({
|
|
7893
7909
|
code: external_exports.ZodIssueCode.custom,
|
|
@@ -9964,14 +9980,14 @@ function taskDirectionSelectionCount(value) {
|
|
|
9964
9980
|
return new Set(value.labelIds ?? []).size + new Set(value.labels ?? []).size;
|
|
9965
9981
|
}
|
|
9966
9982
|
function addExactlyOneTaskDirectionIssue(value, ctx) {
|
|
9967
|
-
const
|
|
9968
|
-
if (
|
|
9983
|
+
const count2 = taskDirectionSelectionCount(value);
|
|
9984
|
+
if (count2 === 1) return;
|
|
9969
9985
|
ctx.addIssue({
|
|
9970
9986
|
code: external_exports.ZodIssueCode.custom,
|
|
9971
9987
|
path: ["labelIds"],
|
|
9972
|
-
message:
|
|
9988
|
+
message: count2 === 0 ? "Task direction is required" : "Exactly one task direction is required",
|
|
9973
9989
|
params: {
|
|
9974
|
-
code:
|
|
9990
|
+
code: count2 === 0 ? "task_direction_required" : "task_direction_exactly_one_required"
|
|
9975
9991
|
}
|
|
9976
9992
|
});
|
|
9977
9993
|
}
|
|
@@ -16698,6 +16714,52 @@ var prerequisiteReleaseReceiptSchema = external_exports.object({
|
|
|
16698
16714
|
}
|
|
16699
16715
|
});
|
|
16700
16716
|
|
|
16717
|
+
// ../shared/src/mirrorx-prerequisite-read-model.ts
|
|
16718
|
+
var prerequisiteTargetWaitSchema = external_exports.enum([
|
|
16719
|
+
"company",
|
|
16720
|
+
"assignee",
|
|
16721
|
+
"interaction",
|
|
16722
|
+
"external",
|
|
16723
|
+
"dependency",
|
|
16724
|
+
"prerequisite",
|
|
16725
|
+
"recovery",
|
|
16726
|
+
"live_owner"
|
|
16727
|
+
]);
|
|
16728
|
+
var prerequisiteRelationshipSchema = external_exports.object({
|
|
16729
|
+
bindingId: external_exports.string().uuid(),
|
|
16730
|
+
requirementId: external_exports.string().uuid(),
|
|
16731
|
+
requirementRevision: external_exports.number().int().positive(),
|
|
16732
|
+
requirementKind: external_exports.string().min(1),
|
|
16733
|
+
sourceAuthorityKind: external_exports.enum(["board_decision", "task_requirement", "registered_validator"]),
|
|
16734
|
+
targetIssueId: external_exports.string().uuid(),
|
|
16735
|
+
targetIdentifier: external_exports.string().nullable(),
|
|
16736
|
+
targetTitle: external_exports.string(),
|
|
16737
|
+
targetExecutionEpoch: external_exports.number().int().positive(),
|
|
16738
|
+
current: external_exports.boolean(),
|
|
16739
|
+
prerequisiteIssueId: external_exports.string().uuid(),
|
|
16740
|
+
prerequisiteIdentifier: external_exports.string().nullable(),
|
|
16741
|
+
prerequisiteTitle: external_exports.string(),
|
|
16742
|
+
state: prerequisiteBindingStateSchema,
|
|
16743
|
+
reasonCode: external_exports.string().nullable(),
|
|
16744
|
+
accepted: external_exports.boolean(),
|
|
16745
|
+
targetWaits: external_exports.array(prerequisiteTargetWaitSchema),
|
|
16746
|
+
escalatedAt: external_exports.string().nullable()
|
|
16747
|
+
}).strict();
|
|
16748
|
+
var prerequisiteAttentionPageSchema = external_exports.object({
|
|
16749
|
+
items: external_exports.array(prerequisiteRelationshipSchema.extend({ attentionId: external_exports.string() }).strict()),
|
|
16750
|
+
nextCursor: external_exports.string().uuid().nullable()
|
|
16751
|
+
}).strict();
|
|
16752
|
+
var interactionSettlementResultSchema = external_exports.object({
|
|
16753
|
+
interactionId: external_exports.string().uuid(),
|
|
16754
|
+
resolutionRevision: external_exports.number().int().positive(),
|
|
16755
|
+
issueExecutionEpoch: external_exports.number().int().positive(),
|
|
16756
|
+
decision: external_exports.enum(["resume_current_issue", "remain_waiting", "terminate_issue", "dedicated_finalizer", "no_issue_transition"]),
|
|
16757
|
+
reasonCode: external_exports.string().min(1),
|
|
16758
|
+
continuationReceiptId: external_exports.string().uuid().nullable(),
|
|
16759
|
+
committedAt: external_exports.string().datetime({ offset: true })
|
|
16760
|
+
}).strict();
|
|
16761
|
+
var interactionSettlementResultsSchema = external_exports.array(interactionSettlementResultSchema);
|
|
16762
|
+
|
|
16701
16763
|
// ../shared/src/mirrorx-prerequisite-recovery.ts
|
|
16702
16764
|
var prerequisiteRecoveryActionSchema = external_exports.enum(["retry_release", "assign_or_reassign_target", "open_staffing_request", "stop_target", "retry", "replace_prerequisite"]);
|
|
16703
16765
|
var decisionBase = external_exports.object({
|
|
@@ -16743,6 +16805,7 @@ var prerequisiteRecoveryReceiptSchema = external_exports.object({
|
|
|
16743
16805
|
}
|
|
16744
16806
|
});
|
|
16745
16807
|
var issuePrerequisitesSchema = external_exports.object({
|
|
16808
|
+
targets: external_exports.array(prerequisiteRelationshipSchema),
|
|
16746
16809
|
companyId: external_exports.string().uuid(),
|
|
16747
16810
|
targetIssueId: external_exports.string().uuid(),
|
|
16748
16811
|
targetExecutionEpoch: external_exports.number().int().positive(),
|
|
@@ -16777,6 +16840,28 @@ var issuePrerequisitesSchema = external_exports.object({
|
|
|
16777
16840
|
}).strict())
|
|
16778
16841
|
}).strict();
|
|
16779
16842
|
|
|
16843
|
+
// ../shared/src/mirrorx-prerequisite-operations.ts
|
|
16844
|
+
var count = external_exports.number().int().nonnegative();
|
|
16845
|
+
var prerequisiteOperationsSchema = external_exports.object({
|
|
16846
|
+
asOf: external_exports.string().datetime(),
|
|
16847
|
+
windowHours: external_exports.literal(24),
|
|
16848
|
+
admission24h: external_exports.object({ sampleSize: count, rejectedCount: count, rejectionRate: external_exports.number().min(0).max(100), boardProposalCount: count }),
|
|
16849
|
+
boardDeferrals24h: count,
|
|
16850
|
+
parked: external_exports.object({ count, slaExceededCount: count, oldestWaitMs: count.nullable() }),
|
|
16851
|
+
churnIdentityCount: count,
|
|
16852
|
+
churn: external_exports.array(external_exports.object({
|
|
16853
|
+
targetIssueId: external_exports.string().uuid(),
|
|
16854
|
+
targetExecutionEpoch: external_exports.number().int().positive(),
|
|
16855
|
+
requirementKind: external_exports.string(),
|
|
16856
|
+
proposals24h: count,
|
|
16857
|
+
decisions24h: count,
|
|
16858
|
+
staleBeforeBind24h: count,
|
|
16859
|
+
generations24h: count,
|
|
16860
|
+
repeatGenerations24h: count,
|
|
16861
|
+
staleDimensions: external_exports.record(count)
|
|
16862
|
+
}))
|
|
16863
|
+
});
|
|
16864
|
+
|
|
16780
16865
|
// src/amaster-runtime-daemon.mjs
|
|
16781
16866
|
import { chmodSync as chmodSync7, copyFileSync as copyFileSync2, existsSync as existsSync17, lstatSync as lstatSync11, mkdirSync as mkdirSync9, mkdtempSync as mkdtempSync2, readFileSync as readFileSync18, readdirSync as readdirSync11, realpathSync as realpathSync8, renameSync as renameSync10, rmSync as rmSync9, statSync as statSync11, symlinkSync as symlinkSync2, unlinkSync as unlinkSync4, writeFileSync as writeFileSync11 } from "node:fs";
|
|
16782
16867
|
import { arch as arch3, homedir as homedir3, hostname as hostname2, platform as platform3, tmpdir } from "node:os";
|
|
@@ -30349,6 +30434,7 @@ function readWorkspaceStatus(cwd, opts = {}) {
|
|
|
30349
30434
|
}
|
|
30350
30435
|
|
|
30351
30436
|
// src/amaster-runtime-daemon/required-task-attachment.mjs
|
|
30437
|
+
var ORIGINAL_ONLY_PARSER_VERSION2 = "original-only-v1";
|
|
30352
30438
|
function text(value) {
|
|
30353
30439
|
return typeof value === "string" && value.trim() ? value.trim() : null;
|
|
30354
30440
|
}
|
|
@@ -30358,9 +30444,10 @@ function number(value) {
|
|
|
30358
30444
|
function assertRequiredTaskAttachmentMaterialized(input, materialized) {
|
|
30359
30445
|
if (input?.kind !== "attachment") return;
|
|
30360
30446
|
if (input.state !== "prepared") throw new Error("required_attachment_not_prepared");
|
|
30447
|
+
const originalOnly = text(input.parserVersion) === ORIGINAL_ONLY_PARSER_VERSION2;
|
|
30361
30448
|
const requirements = [
|
|
30362
30449
|
{ role: "original", assetId: text(input.assetId), sha256: text(input.sha256), byteSize: number(input.byteSize) },
|
|
30363
|
-
{ role: "sidecar", assetId: text(input.sidecarAssetId), sha256: text(input.sidecarSha256), byteSize: number(input.sidecarByteSize) }
|
|
30450
|
+
...originalOnly ? [] : [{ role: "sidecar", assetId: text(input.sidecarAssetId), sha256: text(input.sidecarSha256), byteSize: number(input.sidecarByteSize) }]
|
|
30364
30451
|
];
|
|
30365
30452
|
for (const requirement of requirements) {
|
|
30366
30453
|
if (!requirement.assetId || !/^[a-f0-9]{64}$/iu.test(requirement.sha256 ?? "") || requirement.byteSize === null) {
|
|
@@ -30375,7 +30462,7 @@ function assertRequiredTaskAttachmentMaterialized(input, materialized) {
|
|
|
30375
30462
|
}
|
|
30376
30463
|
|
|
30377
30464
|
// src/amaster-runtime-daemon.mjs
|
|
30378
|
-
var CONNECTOR_VERSION = "0.1.1-beta.
|
|
30465
|
+
var CONNECTOR_VERSION = "0.1.1-beta.235";
|
|
30379
30466
|
var CONNECTOR_CONTRACT_VERSION = "2026-06-04.v1";
|
|
30380
30467
|
var daemonRequire = createRequire(import.meta.url);
|
|
30381
30468
|
var MAX_CHECKPOINT_BYTES = 20 * 1024 * 1024;
|
|
@@ -32714,7 +32801,7 @@ function createLiveOutputLogger(config, command, executorKind, protectedValues =
|
|
|
32714
32801
|
await observationQueue;
|
|
32715
32802
|
if (observationError) throw observationError;
|
|
32716
32803
|
await queue;
|
|
32717
|
-
const suppressedSummaries = Object.entries(suppressedCounts).filter(([,
|
|
32804
|
+
const suppressedSummaries = Object.entries(suppressedCounts).filter(([, count2]) => count2 > 0).map(([stream, count2]) => ({ stream, count: count2 }));
|
|
32718
32805
|
if (suppressedSummaries.length > 0) {
|
|
32719
32806
|
const suppressedCount = suppressedSummaries.reduce((total, summary) => total + summary.count, 0);
|
|
32720
32807
|
await deliverLiveLog({
|
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.235";
|
|
11
11
|
|
|
12
12
|
const CONFIG_KEY_MAP = new Map([
|
|
13
13
|
["server_url", "AMASTER_EMPLOYEE_SERVER_URL"],
|