@memberjunction/core-entities-server 5.40.1 → 5.41.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.
Files changed (48) hide show
  1. package/dist/custom/MJAIAgentCoAgentEntityServer.server.d.ts +78 -0
  2. package/dist/custom/MJAIAgentCoAgentEntityServer.server.d.ts.map +1 -0
  3. package/dist/custom/MJAIAgentCoAgentEntityServer.server.js +224 -0
  4. package/dist/custom/MJAIAgentCoAgentEntityServer.server.js.map +1 -0
  5. package/dist/custom/MJAIAgentEntityServer.server.d.ts +50 -0
  6. package/dist/custom/MJAIAgentEntityServer.server.d.ts.map +1 -0
  7. package/dist/custom/MJAIAgentEntityServer.server.js +126 -0
  8. package/dist/custom/MJAIAgentEntityServer.server.js.map +1 -0
  9. package/dist/custom/MJAIAgentNoteEntityServer.server.d.ts +6 -3
  10. package/dist/custom/MJAIAgentNoteEntityServer.server.d.ts.map +1 -1
  11. package/dist/custom/MJAIAgentNoteEntityServer.server.js +10 -7
  12. package/dist/custom/MJAIAgentNoteEntityServer.server.js.map +1 -1
  13. package/dist/custom/MJAIAgentSessionBridgeEntityServer.server.d.ts +50 -0
  14. package/dist/custom/MJAIAgentSessionBridgeEntityServer.server.d.ts.map +1 -0
  15. package/dist/custom/MJAIAgentSessionBridgeEntityServer.server.js +133 -0
  16. package/dist/custom/MJAIAgentSessionBridgeEntityServer.server.js.map +1 -0
  17. package/dist/custom/MJAIAgentSessionBridgeParticipantEntityServer.server.d.ts +33 -0
  18. package/dist/custom/MJAIAgentSessionBridgeParticipantEntityServer.server.d.ts.map +1 -0
  19. package/dist/custom/MJAIAgentSessionBridgeParticipantEntityServer.server.js +90 -0
  20. package/dist/custom/MJAIAgentSessionBridgeParticipantEntityServer.server.js.map +1 -0
  21. package/dist/custom/MJAIBridgeAgentIdentityEntityServer.server.d.ts +49 -0
  22. package/dist/custom/MJAIBridgeAgentIdentityEntityServer.server.d.ts.map +1 -0
  23. package/dist/custom/MJAIBridgeAgentIdentityEntityServer.server.js +152 -0
  24. package/dist/custom/MJAIBridgeAgentIdentityEntityServer.server.js.map +1 -0
  25. package/dist/custom/MJAIBridgeProviderChannelEntityServer.server.d.ts +33 -0
  26. package/dist/custom/MJAIBridgeProviderChannelEntityServer.server.d.ts.map +1 -0
  27. package/dist/custom/MJAIBridgeProviderChannelEntityServer.server.js +90 -0
  28. package/dist/custom/MJAIBridgeProviderChannelEntityServer.server.js.map +1 -0
  29. package/dist/custom/MJAIBridgeProviderEntityServer.server.d.ts +52 -0
  30. package/dist/custom/MJAIBridgeProviderEntityServer.server.d.ts.map +1 -0
  31. package/dist/custom/MJAIBridgeProviderEntityServer.server.js +154 -0
  32. package/dist/custom/MJAIBridgeProviderEntityServer.server.js.map +1 -0
  33. package/dist/custom/MJAIRemoteBrowserProviderEntityServer.server.d.ts +63 -0
  34. package/dist/custom/MJAIRemoteBrowserProviderEntityServer.server.d.ts.map +1 -0
  35. package/dist/custom/MJAIRemoteBrowserProviderEntityServer.server.js +212 -0
  36. package/dist/custom/MJAIRemoteBrowserProviderEntityServer.server.js.map +1 -0
  37. package/dist/custom/MJDuplicateRunEntityServer.server.d.ts.map +1 -1
  38. package/dist/custom/MJDuplicateRunEntityServer.server.js +45 -4
  39. package/dist/custom/MJDuplicateRunEntityServer.server.js.map +1 -1
  40. package/dist/custom/json-schema-lite.d.ts +36 -0
  41. package/dist/custom/json-schema-lite.d.ts.map +1 -0
  42. package/dist/custom/json-schema-lite.js +125 -0
  43. package/dist/custom/json-schema-lite.js.map +1 -0
  44. package/dist/index.d.ts +9 -0
  45. package/dist/index.d.ts.map +1 -1
  46. package/dist/index.js +9 -0
  47. package/dist/index.js.map +1 -1
  48. package/package.json +24 -24
@@ -9,6 +9,33 @@ import { RegisterClass, GetGlobalObjectStore } from "@memberjunction/global";
9
9
  import { MJDuplicateRunEntity } from "@memberjunction/core-entities";
10
10
  import { DuplicateRecordDetector } from "@memberjunction/ai-vector-dupe";
11
11
  const PIPELINE_PROGRESS_TOPIC = 'PIPELINE_PROGRESS';
12
+ /**
13
+ * Key under which we stash the "detection in flight" set in the MJ global object
14
+ * store. Using the global store (rather than a plain module-level variable) keeps
15
+ * this a true process-singleton even if this module is bundled into more than one
16
+ * execution path — matching the BaseSingleton rationale in the repo guidelines.
17
+ */
18
+ const DETECTION_IN_FLIGHT_KEY = '___MJDuplicateRunDetectionInFlight';
19
+ /**
20
+ * Returns the process-global set of Duplicate Run IDs that currently have a
21
+ * detection pass in flight.
22
+ *
23
+ * WHY THIS EXISTS: {@link MJDuplicateRunEntityServer.runDetectionAsync} drives
24
+ * `DuplicateRecordDetector.GetDuplicateRecords()`, which legitimately re-saves the
25
+ * SAME run record many times mid-run (total-count update, per-batch resume cursor,
26
+ * completion). Every one of those saves re-enters `Save()`, and while `EndedAt` is
27
+ * still null each previously kicked off ANOTHER detection pass — an exponential
28
+ * fan-out that produced thousands of duplicate Duplicate Run Detail rows and
29
+ * eventually failed the run. Guarding on the run ID makes detection fire exactly
30
+ * once per run.
31
+ */
32
+ function detectionInFlightSet() {
33
+ const store = GetGlobalObjectStore();
34
+ if (!store[DETECTION_IN_FLIGHT_KEY]) {
35
+ store[DETECTION_IN_FLIGHT_KEY] = new Set();
36
+ }
37
+ return store[DETECTION_IN_FLIGHT_KEY];
38
+ }
12
39
  /** Map DuplicateDetectionProgress phases to pipeline stage names */
13
40
  const PHASE_TO_STAGE = {
14
41
  'Loading': 'extract',
@@ -21,10 +48,20 @@ const PHASE_TO_STAGE = {
21
48
  let MJDuplicateRunEntityServer = class MJDuplicateRunEntityServer extends MJDuplicateRunEntity {
22
49
  async Save() {
23
50
  const saveResult = await super.Save();
24
- if (saveResult && this.EndedAt === null) {
51
+ // Only kick off detection on the INITIAL save of an unfinished run, and never
52
+ // while a detection pass for this run is already in flight. The detector saves
53
+ // this record repeatedly mid-run (progress + resume cursor) — without this guard
54
+ // each of those saves would spawn another detection pass. See detectionInFlightSet().
55
+ const inFlight = detectionInFlightSet();
56
+ if (saveResult && this.EndedAt === null && !inFlight.has(this.ID)) {
57
+ inFlight.add(this.ID);
25
58
  // Fire-and-forget: run detection asynchronously so the save returns immediately
26
- this.runDetectionAsync().catch((error) => {
59
+ this.runDetectionAsync()
60
+ .catch((error) => {
27
61
  LogError(`Async duplicate detection failed for run ${this.ID}`, undefined, error);
62
+ })
63
+ .finally(() => {
64
+ inFlight.delete(this.ID);
28
65
  });
29
66
  }
30
67
  return saveResult;
@@ -36,12 +73,16 @@ let MJDuplicateRunEntityServer = class MJDuplicateRunEntityServer extends MJDupl
36
73
  async runDetectionAsync() {
37
74
  const startTime = Date.now();
38
75
  try {
39
- const detector = new DuplicateRecordDetector();
76
+ // Thread this entity's provider (request-scoped — each MJAPI call binds its own
77
+ // connection) down the detection stack instead of letting it fall back to the
78
+ // process-global default provider.
79
+ const provider = this.ProviderToUse;
80
+ const detector = new DuplicateRecordDetector(provider);
40
81
  const request = new PotentialDuplicateRequest();
41
82
  request.EntityID = this.EntityID;
42
83
  request.ListID = this.SourceListID || undefined; // Optional — if not set, scans all entity records
43
84
  // Find the first active entity document for this entity to get template/thresholds
44
- const rv = new RunView();
85
+ const rv = new RunView(this.RunViewProviderToUse);
45
86
  const edResult = await rv.RunView({
46
87
  EntityName: 'MJ: Entity Documents',
47
88
  ExtraFilter: `EntityID='${this.EntityID}' AND Status='Active'`,
@@ -1 +1 @@
1
- {"version":3,"file":"MJDuplicateRunEntityServer.server.js","sourceRoot":"","sources":["../../src/custom/MJDuplicateRunEntityServer.server.ts"],"names":[],"mappings":";;;;;;AAAA,OAAO,EAAE,UAAU,EAAyD,QAAQ,EAAE,SAAS,EAAE,yBAAyB,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AAClK,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC7E,OAAO,EAAE,oBAAoB,EAA0B,MAAM,+BAA+B,CAAC;AAC7F,OAAO,EAAE,uBAAuB,EAAE,MAAM,gCA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AK,CAAC,CAAC;QACzF,CAAC;IACL,CAAC;CACJ,CAAA;AArJY,0BAA0B;IADtC,aAAa,CAAC,UAAU,EAAE,oBAAoB,CAAC;GACnC,0BAA0B,CAqJtC"}
1
+ {"version":3,"file":"MJDuplicateRunEntityServer.server.js","sourceRoot":"","sources":["../../src/custom/MJDuplicateRunEntityServer.server.ts"],"names":[],"mappings":";;;;;;AAAA,OAAO,EAAE,UAAU,EAA4E,QAAQ,EAAE,SAAS,EAAE,yBAAyB,EAAE,OAAO,EAAE,MAAM,sBAAsB,CAAC;AACrL,OAAO,EAAE,aAAa,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC7E,OAAO,EAAE,oBAAoB,EAA0B,MAAM,+BAA+B,CAAC;AAC7F,OAAO,EAAE,uBAAuB,EAAE,MAAM,gCAAgC,CAAC;AAEzE,MAAM,uBAAuB,GAAG,mBAAmB,CAAC;AAEpD;;;;;GAKG;AACH,MAAM,uBAAuB,GAAG,oCAAoC,CAAC;AAErE;;;;;;;;;;;;GAYG;AACH,SAAS,oBAAoB;IACzB,MAAM,KAAK,GAAG,oBAAoB,EAAE,CAAC;IACrC,IAAI,CAAC,KAAK,CAAC,uBAAuB,CAAC,EAAE,CAAC;QAClC,KAAK,CAAC,uBAAuB,CAAC,GAAG,IAAI,GAAG,EAAU,CAAC;IACvD,CAAC;IACD,OAAO,KAAK,CAAC,uBAAuB,CAAgB,CAAC;AACzD,CAAC;AAED,oEAAoE;AACpE,MAAM,cAAc,GAAwD;IACxE,SAAS,EAAE,SAAS;IACpB,aAAa,EAAE,WAAW;IAC1B,WAAW,EAAE,SAAS;IACtB,UAAU,EAAE,SAAS;IACrB,UAAU,EAAE,SAAS;IACrB,SAAS,EAAE,UAAU;CACxB,CAAC;AAGK,IAAM,0BAA0B,GAAhC,MAAM,0BAA2B,SAAQ,oBAAoB;IACzD,KAAK,CAAC,IAAI;QACb,MAAM,UAAU,GAAY,MAAM,KAAK,CAAC,IAAI,EAAE,CAA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b,uDAAuD;YACvD,QAAQ,CAAC,+CAA+C,IAAI,CAAC,EAAE,EAAE,EAAE,SAAS,EAAE,KAAK,CAAC,CAAC;QACzF,CAAC;IACL,CAAC;CACJ,CAAA;AAnKY,0BAA0B;IADtC,aAAa,CAAC,UAAU,EAAE,oBAAoB,CAAC;GACnC,0BAA0B,CAmKtC"}
@@ -0,0 +1,36 @@
1
+ /**
2
+ * @fileoverview Lightweight JSON-Schema-subset validator used by server-side entity
3
+ * subclasses to validate configuration JSON against a published schema (e.g.
4
+ * `AIAgent.TypeConfiguration` against `AIAgentType.ConfigSchema`).
5
+ *
6
+ * Deliberately NOT a full draft-07 implementation and deliberately dependency-free (no `ajv`):
7
+ * type/required/properties/enum/items/additionalProperties checks are enough for the
8
+ * configuration shapes MJ publishes, and unknown keywords are IGNORED (forward-compatible —
9
+ * a schema using a keyword this validator doesn't know simply isn't enforced on that axis).
10
+ *
11
+ * Supported keywords:
12
+ * - `type` — `"object" | "array" | "string" | "number" | "integer" | "boolean" | "null"`,
13
+ * or an array of those (union).
14
+ * - `properties` — per-key subschemas, recursed.
15
+ * - `required` — array of required property names (applies to objects).
16
+ * - `enum` — allowed literal values (strict equality on primitives).
17
+ * - `items` — single subschema applied to every array element.
18
+ * - `additionalProperties` — `false` rejects keys not listed in `properties`; any other value
19
+ * (including a subschema) is ignored.
20
+ *
21
+ * @module @memberjunction/core-entities-server
22
+ */
23
+ /** A parsed JSON Schema (subset) node. */
24
+ export type JsonSchemaLite = Record<string, unknown>;
25
+ /**
26
+ * Validates a parsed JSON value against a JSON-Schema-subset node, returning human-readable
27
+ * error strings (empty array = valid). Never throws — a malformed schema node is skipped
28
+ * (its constraints simply aren't enforced).
29
+ *
30
+ * @param value The parsed JSON value to validate.
31
+ * @param schema The parsed schema node.
32
+ * @param path JSON-path-ish location prefix used in error messages (defaults to `$`).
33
+ * @returns The list of violations (empty when valid).
34
+ */
35
+ export declare function ValidateJsonAgainstSchemaLite(value: unknown, schema: JsonSchemaLite, path?: string): string[];
36
+ //# sourceMappingURL=json-schema-lite.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"json-schema-lite.d.ts","sourceRoot":"","sources":["../../src/custom/json-schema-lite.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAEH,0CAA0C;AAC1C,MAAM,MAAM,cAAc,GAAG,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;AAyBrD;;;;;;;;;GASG;AACH,wBAAgB,6BAA6B,CAAC,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,cAAc,EAAE,IAAI,GAAE,MAAY,GAAG,MAAM,EAAE,CAkBlH"}
@@ -0,0 +1,125 @@
1
+ /**
2
+ * @fileoverview Lightweight JSON-Schema-subset validator used by server-side entity
3
+ * subclasses to validate configuration JSON against a published schema (e.g.
4
+ * `AIAgent.TypeConfiguration` against `AIAgentType.ConfigSchema`).
5
+ *
6
+ * Deliberately NOT a full draft-07 implementation and deliberately dependency-free (no `ajv`):
7
+ * type/required/properties/enum/items/additionalProperties checks are enough for the
8
+ * configuration shapes MJ publishes, and unknown keywords are IGNORED (forward-compatible —
9
+ * a schema using a keyword this validator doesn't know simply isn't enforced on that axis).
10
+ *
11
+ * Supported keywords:
12
+ * - `type` — `"object" | "array" | "string" | "number" | "integer" | "boolean" | "null"`,
13
+ * or an array of those (union).
14
+ * - `properties` — per-key subschemas, recursed.
15
+ * - `required` — array of required property names (applies to objects).
16
+ * - `enum` — allowed literal values (strict equality on primitives).
17
+ * - `items` — single subschema applied to every array element.
18
+ * - `additionalProperties` — `false` rejects keys not listed in `properties`; any other value
19
+ * (including a subschema) is ignored.
20
+ *
21
+ * @module @memberjunction/core-entities-server
22
+ */
23
+ /** True for a plain JSON object (not null, not an array). */
24
+ function isPlainObject(value) {
25
+ return value !== null && typeof value === 'object' && !Array.isArray(value);
26
+ }
27
+ /** Maps a runtime value onto its JSON-Schema type name. */
28
+ function jsonTypeOf(value) {
29
+ if (value === null)
30
+ return 'null';
31
+ if (Array.isArray(value))
32
+ return 'array';
33
+ switch (typeof value) {
34
+ case 'string': return 'string';
35
+ case 'number': return Number.isInteger(value) ? 'integer' : 'number';
36
+ case 'boolean': return 'boolean';
37
+ case 'object': return 'object';
38
+ default: return typeof value;
39
+ }
40
+ }
41
+ /** True when a runtime JSON type name satisfies a schema type name (`integer` ⊂ `number`). */
42
+ function typeSatisfies(actual, expected) {
43
+ return actual === expected || (expected === 'number' && actual === 'integer');
44
+ }
45
+ /**
46
+ * Validates a parsed JSON value against a JSON-Schema-subset node, returning human-readable
47
+ * error strings (empty array = valid). Never throws — a malformed schema node is skipped
48
+ * (its constraints simply aren't enforced).
49
+ *
50
+ * @param value The parsed JSON value to validate.
51
+ * @param schema The parsed schema node.
52
+ * @param path JSON-path-ish location prefix used in error messages (defaults to `$`).
53
+ * @returns The list of violations (empty when valid).
54
+ */
55
+ export function ValidateJsonAgainstSchemaLite(value, schema, path = '$') {
56
+ const errors = [];
57
+ if (!isPlainObject(schema)) {
58
+ return errors;
59
+ }
60
+ validateType(value, schema, path, errors);
61
+ validateEnum(value, schema, path, errors);
62
+ if (isPlainObject(value)) {
63
+ validateObjectKeywords(value, schema, path, errors);
64
+ }
65
+ if (Array.isArray(value) && isPlainObject(schema['items'])) {
66
+ value.forEach((element, index) => {
67
+ errors.push(...ValidateJsonAgainstSchemaLite(element, schema['items'], `${path}[${index}]`));
68
+ });
69
+ }
70
+ return errors;
71
+ }
72
+ /** Enforces the `type` keyword (string or union array). */
73
+ function validateType(value, schema, path, errors) {
74
+ const expected = schema['type'];
75
+ if (expected === undefined) {
76
+ return;
77
+ }
78
+ const expectedList = Array.isArray(expected) ? expected : [expected];
79
+ const names = expectedList.filter((t) => typeof t === 'string');
80
+ if (names.length === 0) {
81
+ return; // malformed type keyword — skipped
82
+ }
83
+ const actual = jsonTypeOf(value);
84
+ if (!names.some((t) => typeSatisfies(actual, t))) {
85
+ errors.push(`${path}: expected type ${names.join(' | ')}, got ${actual}`);
86
+ }
87
+ }
88
+ /** Enforces the `enum` keyword (strict primitive equality). */
89
+ function validateEnum(value, schema, path, errors) {
90
+ const allowed = schema['enum'];
91
+ if (!Array.isArray(allowed) || allowed.length === 0) {
92
+ return;
93
+ }
94
+ if (!allowed.some((candidate) => candidate === value)) {
95
+ const rendered = allowed.map((c) => JSON.stringify(c)).join(', ');
96
+ errors.push(`${path}: value ${JSON.stringify(value)} is not one of the allowed values [${rendered}]`);
97
+ }
98
+ }
99
+ /** Enforces `required`, `properties` recursion, and `additionalProperties: false` on objects. */
100
+ function validateObjectKeywords(value, schema, path, errors) {
101
+ const required = schema['required'];
102
+ if (Array.isArray(required)) {
103
+ for (const name of required) {
104
+ if (typeof name === 'string' && !(name in value)) {
105
+ errors.push(`${path}: missing required property '${name}'`);
106
+ }
107
+ }
108
+ }
109
+ const properties = isPlainObject(schema['properties']) ? schema['properties'] : undefined;
110
+ if (properties) {
111
+ for (const key of Object.keys(properties)) {
112
+ if (key in value && isPlainObject(properties[key])) {
113
+ errors.push(...ValidateJsonAgainstSchemaLite(value[key], properties[key], `${path}.${key}`));
114
+ }
115
+ }
116
+ if (schema['additionalProperties'] === false) {
117
+ for (const key of Object.keys(value)) {
118
+ if (!(key in properties)) {
119
+ errors.push(`${path}: unexpected property '${key}' (additionalProperties is false)`);
120
+ }
121
+ }
122
+ }
123
+ }
124
+ }
125
+ //# sourceMappingURL=json-schema-lite.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"json-schema-lite.js","sourceRoot":"","sources":["../../src/custom/json-schema-lite.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;GAqBG;AAKH,6DAA6D;AAC7D,SAAS,aAAa,CAAC,KAAc;IACjC,OAAO,KAAK,KAAK,IAAI,IAAI,OAAO,KAAK,KAAK,QAAQ,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,CAAC;AAChF,CAAC;AAED,2DAA2D;AAC3D,SAAS,UAAU,C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AAS,CAAC;IAC1F,IAAI,UAAU,EAAE,CAAC;QACb,KAAK,MAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE,CAAC;YACxC,IAAI,GAAG,IAAI,KAAK,IAAI,aAAa,CAAC,UAAU,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC;gBACjD,MAAM,CAAC,IAAI,CAAC,GAAG,6BAA6B,CAAC,KAAK,CAAC,GAAG,CAAC,EAAE,UAAU,CAAC,GAAG,CAAmB,EAAE,GAAG,IAAI,IAAI,GAAG,EAAE,CAAC,CAAC,CAAC;YACnH,CAAC;QACL,CAAC;QACD,IAAI,MAAM,CAAC,sBAAsB,CAAC,KAAK,KAAK,EAAE,CAAC;YAC3C,KAAK,MAAM,GAAG,IAAI,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,EAAE,CAAC;gBACnC,IAAI,CAAC,CAAC,GAAG,IAAI,UAAU,CAAC,EAAE,CAAC;oBACvB,MAAM,CAAC,IAAI,CAAC,GAAG,IAAI,0BAA0B,GAAG,mCAAmC,CAAC,CAAC;gBACzF,CAAC;YACL,CAAC;QACL,CAAC;IACL,CAAC;AACL,CAAC"}
package/dist/index.d.ts CHANGED
@@ -18,6 +18,15 @@ export * from './custom/MJTagEntityServer.server.js';
18
18
  export * from './custom/MJSearchScopeEntityServer.server.js';
19
19
  export * from './custom/MJTagScopeEntityServer.server.js';
20
20
  export * from './custom/MJCompanyIntegrationEntityServer.server.js';
21
+ export * from './custom/MJAIAgentEntityServer.server.js';
22
+ export * from './custom/MJAIAgentCoAgentEntityServer.server.js';
23
+ export * from './custom/MJAIBridgeProviderEntityServer.server.js';
24
+ export * from './custom/MJAIBridgeAgentIdentityEntityServer.server.js';
25
+ export * from './custom/MJAIBridgeProviderChannelEntityServer.server.js';
26
+ export * from './custom/MJAIAgentSessionBridgeEntityServer.server.js';
27
+ export * from './custom/MJAIAgentSessionBridgeParticipantEntityServer.server.js';
28
+ export * from './custom/MJAIRemoteBrowserProviderEntityServer.server.js';
29
+ export * from './custom/json-schema-lite.js';
21
30
  export * from './custom/IntegrationLLMPKCallback.js';
22
31
  export * from './custom/util.js';
23
32
  export * from './engines/QueryEngineServer.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,wCAAwC,CAAC;AACvD,cAAc,8CAA8C,CAAC;AAC7D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,kDAAkD,CAAC;AACjE,cAAc,4DAA4D,CAAC;AAC3E,cAAc,4CAA4C,CAAC;AAC3D,cAAc,qCAAqC,CAAC;AACpD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,wCAAwC,CAAC;AACvD,cAAc,sCAAsC,CAAC;AACrD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,yCAAyC,CAAC;AACxD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,8CAA8C,CAAC;AAC7D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,mCAAmC,CAAC;AAClD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,wCAAwC,CAAC;AACvD,cAAc,kDAAkD,CAAC;AACjE,cAAc,mCAAmC,CAAC;AAClD,cAAc,eAAe,CAAC;AAE9B,cAAc,6BAA6B,CAAC;AAC5C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,yCAAyC,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,wCAAwC,CAAC;AACvD,cAAc,8CAA8C,CAAC;AAC7D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,kDAAkD,CAAC;AACjE,cAAc,4DAA4D,CAAC;AAC3E,cAAc,4CAA4C,CAAC;AAC3D,cAAc,qCAAqC,CAAC;AACpD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,wCAAwC,CAAC;AACvD,cAAc,sCAAsC,CAAC;AACrD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,yCAAyC,CAAC;AACxD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,8CAA8C,CAAC;AAC7D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,mCAAmC,CAAC;AAClD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,wCAAwC,CAAC;AACvD,cAAc,kDAAkD,CAAC;AACjE,cAAc,uCAAuC,CAAC;AACtD,cAAc,8CAA8C,CAAC;AAC7D,cAAc,gDAAgD,CAAC;AAC/D,cAAc,qDAAqD,CAAC;AACpE,cAAc,uDAAuD,CAAC;AACtE,cAAc,oDAAoD,CAAC;AACnE,cAAc,+DAA+D,CAAC;AAC9E,cAAc,uDAAuD,CAAC;AACtE,cAAc,2BAA2B,CAAC;AAC1C,cAAc,mCAAmC,CAAC;AAClD,cAAc,eAAe,CAAC;AAE9B,cAAc,6BAA6B,CAAC;AAC5C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,yCAAyC,CAAC"}
package/dist/index.js CHANGED
@@ -18,6 +18,15 @@ export * from './custom/MJTagEntityServer.server.js';
18
18
  export * from './custom/MJSearchScopeEntityServer.server.js';
19
19
  export * from './custom/MJTagScopeEntityServer.server.js';
20
20
  export * from './custom/MJCompanyIntegrationEntityServer.server.js';
21
+ export * from './custom/MJAIAgentEntityServer.server.js';
22
+ export * from './custom/MJAIAgentCoAgentEntityServer.server.js';
23
+ export * from './custom/MJAIBridgeProviderEntityServer.server.js';
24
+ export * from './custom/MJAIBridgeAgentIdentityEntityServer.server.js';
25
+ export * from './custom/MJAIBridgeProviderChannelEntityServer.server.js';
26
+ export * from './custom/MJAIAgentSessionBridgeEntityServer.server.js';
27
+ export * from './custom/MJAIAgentSessionBridgeParticipantEntityServer.server.js';
28
+ export * from './custom/MJAIRemoteBrowserProviderEntityServer.server.js';
29
+ export * from './custom/json-schema-lite.js';
21
30
  export * from './custom/IntegrationLLMPKCallback.js';
22
31
  export * from './custom/util.js';
23
32
  export * from './engines/QueryEngineServer.js';
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,wCAAwC,CAAC;AACvD,cAAc,8CAA8C,CAAC;AAC7D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,kDAAkD,CAAC;AACjE,cAAc,4DAA4D,CAAC;AAC3E,cAAc,4CAA4C,CAAC;AAC3D,cAAc,qCAAqC,CAAC;AACpD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,wCAAwC,CAAC;AACvD,cAAc,sCAAsC,CAAC;AACrD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,yCAAyC,CAAC;AACxD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,8CAA8C,CAAC;AAC7D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,mCAAmC,CAAC;AAClD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,wCAAwC,CAAC;AACvD,cAAc,kDAAkD,CAAC;AACjE,cAAc,mCAAmC,CAAC;AAClD,cAAc,eAAe,CAAC;AAE9B,cAAc,6BAA6B,CAAC;AAC5C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,yCAAyC,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,wCAAwC,CAAC;AACvD,cAAc,8CAA8C,CAAC;AAC7D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,kDAAkD,CAAC;AACjE,cAAc,4DAA4D,CAAC;AAC3E,cAAc,4CAA4C,CAAC;AAC3D,cAAc,qCAAqC,CAAC;AACpD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,wCAAwC,CAAC;AACvD,cAAc,sCAAsC,CAAC;AACrD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,yCAAyC,CAAC;AACxD,cAAc,+CAA+C,CAAC;AAC9D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,8CAA8C,CAAC;AAC7D,cAAc,2CAA2C,CAAC;AAC1D,cAAc,mCAAmC,CAAC;AAClD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,wCAAwC,CAAC;AACvD,cAAc,kDAAkD,CAAC;AACjE,cAAc,uCAAuC,CAAC;AACtD,cAAc,8CAA8C,CAAC;AAC7D,cAAc,gDAAgD,CAAC;AAC/D,cAAc,qDAAqD,CAAC;AACpE,cAAc,uDAAuD,CAAC;AACtE,cAAc,oDAAoD,CAAC;AACnE,cAAc,+DAA+D,CAAC;AAC9E,cAAc,uDAAuD,CAAC;AACtE,cAAc,2BAA2B,CAAC;AAC1C,cAAc,mCAAmC,CAAC;AAClD,cAAc,eAAe,CAAC;AAE9B,cAAc,6BAA6B,CAAC;AAC5C,cAAc,4BAA4B,CAAC;AAC3C,cAAc,yCAAyC,CAAC"}
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@memberjunction/core-entities-server",
3
3
  "type": "module",
4
- "version": "5.40.1",
4
+ "version": "5.41.0",
5
5
  "description": "Entity subclasses for the metadata layer of MemberJunction that are only used on server side applications like MJAPI, distributed as part of each release of MemberJunction",
6
6
  "main": "dist/index.js",
7
7
  "types": "dist/index.d.ts",
@@ -21,29 +21,29 @@
21
21
  "typescript": "^5.9.3"
22
22
  },
23
23
  "dependencies": {
24
- "@memberjunction/actions-base": "5.40.1",
25
- "@memberjunction/ai": "5.40.1",
26
- "@memberjunction/ai-core-plus": "5.40.1",
27
- "@memberjunction/ai-engine-base": "5.40.1",
28
- "@memberjunction/ai-prompts": "5.40.1",
29
- "@memberjunction/ai-provider-bundle": "5.40.1",
30
- "@memberjunction/ai-vector-dupe": "5.40.1",
31
- "@memberjunction/ai-vectordb": "5.40.1",
32
- "@memberjunction/ai-vectors-memory": "5.40.1",
33
- "@memberjunction/aiengine": "5.40.1",
34
- "@memberjunction/core": "5.40.1",
35
- "@memberjunction/core-entities": "5.40.1",
36
- "@memberjunction/doc-utils": "5.40.1",
37
- "@memberjunction/generic-database-provider": "5.40.1",
38
- "@memberjunction/global": "5.40.1",
39
- "@memberjunction/integration-engine": "5.40.1",
40
- "@memberjunction/integration-pk-classifier": "5.40.1",
41
- "@memberjunction/skip-types": "5.40.1",
42
- "@memberjunction/sql-converter": "5.40.1",
43
- "@memberjunction/sql-dialect": "5.40.1",
44
- "@memberjunction/sql-parser": "5.40.1",
45
- "@memberjunction/sqlserver-dataprovider": "5.40.1",
46
- "@memberjunction/tag-engine": "5.40.1",
24
+ "@memberjunction/actions-base": "5.41.0",
25
+ "@memberjunction/ai": "5.41.0",
26
+ "@memberjunction/ai-core-plus": "5.41.0",
27
+ "@memberjunction/ai-engine-base": "5.41.0",
28
+ "@memberjunction/ai-prompts": "5.41.0",
29
+ "@memberjunction/ai-provider-bundle": "5.41.0",
30
+ "@memberjunction/ai-vector-dupe": "5.41.0",
31
+ "@memberjunction/ai-vectordb": "5.41.0",
32
+ "@memberjunction/ai-vectors-memory": "5.41.0",
33
+ "@memberjunction/aiengine": "5.41.0",
34
+ "@memberjunction/core": "5.41.0",
35
+ "@memberjunction/core-entities": "5.41.0",
36
+ "@memberjunction/doc-utils": "5.41.0",
37
+ "@memberjunction/generic-database-provider": "5.41.0",
38
+ "@memberjunction/global": "5.41.0",
39
+ "@memberjunction/integration-engine": "5.41.0",
40
+ "@memberjunction/integration-pk-classifier": "5.41.0",
41
+ "@memberjunction/skip-types": "5.41.0",
42
+ "@memberjunction/sql-converter": "5.41.0",
43
+ "@memberjunction/sql-dialect": "5.41.0",
44
+ "@memberjunction/sql-parser": "5.41.0",
45
+ "@memberjunction/sqlserver-dataprovider": "5.41.0",
46
+ "@memberjunction/tag-engine": "5.41.0",
47
47
  "nunjucks": "3.2.4",
48
48
  "rxjs": "~7.8.1",
49
49
  "zod": "~3.24.4"