@memberjunction/server 2.111.1 → 2.113.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/generated/generated.d.ts +140 -10
- package/dist/generated/generated.d.ts.map +1 -1
- package/dist/generated/generated.js +923 -74
- package/dist/generated/generated.js.map +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -0
- package/dist/index.js.map +1 -1
- package/package.json +39 -37
- package/src/generated/generated.ts +590 -54
- package/src/index.ts +6 -0
|
@@ -2535,8 +2535,8 @@ let MJAIAgentRun_ = class MJAIAgentRun_ {
|
|
|
2535
2535
|
RootLastRunID;
|
|
2536
2536
|
MJ_AIAgentRunSteps_AgentRunIDArray;
|
|
2537
2537
|
MJ_AIAgentRuns_ParentRunIDArray;
|
|
2538
|
-
AIAgentNotes_SourceAIAgentRunIDArray;
|
|
2539
2538
|
MJ_AIAgentExamples_SourceAIAgentRunIDArray;
|
|
2539
|
+
AIAgentNotes_SourceAIAgentRunIDArray;
|
|
2540
2540
|
MJ_AIPromptRuns_AgentRunIDArray;
|
|
2541
2541
|
};
|
|
2542
2542
|
__decorate([
|
|
@@ -2767,14 +2767,14 @@ __decorate([
|
|
|
2767
2767
|
Field(() => [MJAIAgentRun_]),
|
|
2768
2768
|
__metadata("design:type", Array)
|
|
2769
2769
|
], MJAIAgentRun_.prototype, "MJ_AIAgentRuns_ParentRunIDArray", void 0);
|
|
2770
|
-
__decorate([
|
|
2771
|
-
Field(() => [MJAIAgentNote_]),
|
|
2772
|
-
__metadata("design:type", Array)
|
|
2773
|
-
], MJAIAgentRun_.prototype, "AIAgentNotes_SourceAIAgentRunIDArray", void 0);
|
|
2774
2770
|
__decorate([
|
|
2775
2771
|
Field(() => [MJAIAgentExample_]),
|
|
2776
2772
|
__metadata("design:type", Array)
|
|
2777
2773
|
], MJAIAgentRun_.prototype, "MJ_AIAgentExamples_SourceAIAgentRunIDArray", void 0);
|
|
2774
|
+
__decorate([
|
|
2775
|
+
Field(() => [MJAIAgentNote_]),
|
|
2776
|
+
__metadata("design:type", Array)
|
|
2777
|
+
], MJAIAgentRun_.prototype, "AIAgentNotes_SourceAIAgentRunIDArray", void 0);
|
|
2778
2778
|
__decorate([
|
|
2779
2779
|
Field(() => [MJAIPromptRun_]),
|
|
2780
2780
|
__metadata("design:type", Array)
|
|
@@ -3262,22 +3262,22 @@ let MJAIAgentRunResolver = class MJAIAgentRunResolver extends ResolverBase {
|
|
|
3262
3262
|
const result = this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Runs', rows);
|
|
3263
3263
|
return result;
|
|
3264
3264
|
}
|
|
3265
|
-
async
|
|
3266
|
-
this.CheckUserReadPermissions('AI Agent
|
|
3265
|
+
async MJ_AIAgentExamples_SourceAIAgentRunIDArray(mjaiagentrun_, { dataSources, userPayload, providers }, pubSub) {
|
|
3266
|
+
this.CheckUserReadPermissions('MJ: AI Agent Examples', userPayload);
|
|
3267
3267
|
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
3268
3268
|
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
3269
|
-
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[
|
|
3269
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwAIAgentExamples] WHERE [SourceAIAgentRunID]='${mjaiagentrun_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Agent Examples', userPayload, EntityPermissionType.Read, 'AND');
|
|
3270
3270
|
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
3271
|
-
const result = this.ArrayMapFieldNamesToCodeNames('AI Agent
|
|
3271
|
+
const result = this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Examples', rows);
|
|
3272
3272
|
return result;
|
|
3273
3273
|
}
|
|
3274
|
-
async
|
|
3275
|
-
this.CheckUserReadPermissions('
|
|
3274
|
+
async AIAgentNotes_SourceAIAgentRunIDArray(mjaiagentrun_, { dataSources, userPayload, providers }, pubSub) {
|
|
3275
|
+
this.CheckUserReadPermissions('AI Agent Notes', userPayload);
|
|
3276
3276
|
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
3277
3277
|
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
3278
|
-
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[
|
|
3278
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwAIAgentNotes] WHERE [SourceAIAgentRunID]='${mjaiagentrun_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'AI Agent Notes', userPayload, EntityPermissionType.Read, 'AND');
|
|
3279
3279
|
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
3280
|
-
const result = this.ArrayMapFieldNamesToCodeNames('
|
|
3280
|
+
const result = this.ArrayMapFieldNamesToCodeNames('AI Agent Notes', rows);
|
|
3281
3281
|
return result;
|
|
3282
3282
|
}
|
|
3283
3283
|
async MJ_AIPromptRuns_AgentRunIDArray(mjaiagentrun_, { dataSources, userPayload, providers }, pubSub) {
|
|
@@ -3358,23 +3358,23 @@ __decorate([
|
|
|
3358
3358
|
__metadata("design:returntype", Promise)
|
|
3359
3359
|
], MJAIAgentRunResolver.prototype, "MJ_AIAgentRuns_ParentRunIDArray", null);
|
|
3360
3360
|
__decorate([
|
|
3361
|
-
FieldResolver(() => [
|
|
3361
|
+
FieldResolver(() => [MJAIAgentExample_]),
|
|
3362
3362
|
__param(0, Root()),
|
|
3363
3363
|
__param(1, Ctx()),
|
|
3364
3364
|
__param(2, PubSub()),
|
|
3365
3365
|
__metadata("design:type", Function),
|
|
3366
3366
|
__metadata("design:paramtypes", [MJAIAgentRun_, Object, PubSubEngine]),
|
|
3367
3367
|
__metadata("design:returntype", Promise)
|
|
3368
|
-
], MJAIAgentRunResolver.prototype, "
|
|
3368
|
+
], MJAIAgentRunResolver.prototype, "MJ_AIAgentExamples_SourceAIAgentRunIDArray", null);
|
|
3369
3369
|
__decorate([
|
|
3370
|
-
FieldResolver(() => [
|
|
3370
|
+
FieldResolver(() => [MJAIAgentNote_]),
|
|
3371
3371
|
__param(0, Root()),
|
|
3372
3372
|
__param(1, Ctx()),
|
|
3373
3373
|
__param(2, PubSub()),
|
|
3374
3374
|
__metadata("design:type", Function),
|
|
3375
3375
|
__metadata("design:paramtypes", [MJAIAgentRun_, Object, PubSubEngine]),
|
|
3376
3376
|
__metadata("design:returntype", Promise)
|
|
3377
|
-
], MJAIAgentRunResolver.prototype, "
|
|
3377
|
+
], MJAIAgentRunResolver.prototype, "AIAgentNotes_SourceAIAgentRunIDArray", null);
|
|
3378
3378
|
__decorate([
|
|
3379
3379
|
FieldResolver(() => [MJAIPromptRun_]),
|
|
3380
3380
|
__param(0, Root()),
|
|
@@ -4070,9 +4070,9 @@ let MJAIConfiguration_ = class MJAIConfiguration_ {
|
|
|
4070
4070
|
DefaultPromptForContextSummarization;
|
|
4071
4071
|
MJ_AIConfigurationParams_ConfigurationIDArray;
|
|
4072
4072
|
MJ_AIAgentPrompts_ConfigurationIDArray;
|
|
4073
|
+
MJ_AIPromptRuns_ConfigurationIDArray;
|
|
4073
4074
|
MJ_AIPromptModels_ConfigurationIDArray;
|
|
4074
4075
|
AIResultCache_ConfigurationIDArray;
|
|
4075
|
-
MJ_AIPromptRuns_ConfigurationIDArray;
|
|
4076
4076
|
MJ_AIAgentRuns_ConfigurationIDArray;
|
|
4077
4077
|
};
|
|
4078
4078
|
__decorate([
|
|
@@ -4136,6 +4136,10 @@ __decorate([
|
|
|
4136
4136
|
Field(() => [MJAIAgentPrompt_]),
|
|
4137
4137
|
__metadata("design:type", Array)
|
|
4138
4138
|
], MJAIConfiguration_.prototype, "MJ_AIAgentPrompts_ConfigurationIDArray", void 0);
|
|
4139
|
+
__decorate([
|
|
4140
|
+
Field(() => [MJAIPromptRun_]),
|
|
4141
|
+
__metadata("design:type", Array)
|
|
4142
|
+
], MJAIConfiguration_.prototype, "MJ_AIPromptRuns_ConfigurationIDArray", void 0);
|
|
4139
4143
|
__decorate([
|
|
4140
4144
|
Field(() => [MJAIPromptModel_]),
|
|
4141
4145
|
__metadata("design:type", Array)
|
|
@@ -4144,10 +4148,6 @@ __decorate([
|
|
|
4144
4148
|
Field(() => [MJAIResultCache_]),
|
|
4145
4149
|
__metadata("design:type", Array)
|
|
4146
4150
|
], MJAIConfiguration_.prototype, "AIResultCache_ConfigurationIDArray", void 0);
|
|
4147
|
-
__decorate([
|
|
4148
|
-
Field(() => [MJAIPromptRun_]),
|
|
4149
|
-
__metadata("design:type", Array)
|
|
4150
|
-
], MJAIConfiguration_.prototype, "MJ_AIPromptRuns_ConfigurationIDArray", void 0);
|
|
4151
4151
|
__decorate([
|
|
4152
4152
|
Field(() => [MJAIAgentRun_]),
|
|
4153
4153
|
__metadata("design:type", Array)
|
|
@@ -4325,6 +4325,15 @@ let MJAIConfigurationResolver = class MJAIConfigurationResolver extends Resolver
|
|
|
4325
4325
|
const result = this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Prompts', rows);
|
|
4326
4326
|
return result;
|
|
4327
4327
|
}
|
|
4328
|
+
async MJ_AIPromptRuns_ConfigurationIDArray(mjaiconfiguration_, { dataSources, userPayload, providers }, pubSub) {
|
|
4329
|
+
this.CheckUserReadPermissions('MJ: AI Prompt Runs', userPayload);
|
|
4330
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
4331
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
4332
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwAIPromptRuns] WHERE [ConfigurationID]='${mjaiconfiguration_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Prompt Runs', userPayload, EntityPermissionType.Read, 'AND');
|
|
4333
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
4334
|
+
const result = this.ArrayMapFieldNamesToCodeNames('MJ: AI Prompt Runs', rows);
|
|
4335
|
+
return result;
|
|
4336
|
+
}
|
|
4328
4337
|
async MJ_AIPromptModels_ConfigurationIDArray(mjaiconfiguration_, { dataSources, userPayload, providers }, pubSub) {
|
|
4329
4338
|
this.CheckUserReadPermissions('MJ: AI Prompt Models', userPayload);
|
|
4330
4339
|
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
@@ -4343,15 +4352,6 @@ let MJAIConfigurationResolver = class MJAIConfigurationResolver extends Resolver
|
|
|
4343
4352
|
const result = this.ArrayMapFieldNamesToCodeNames('AI Result Cache', rows);
|
|
4344
4353
|
return result;
|
|
4345
4354
|
}
|
|
4346
|
-
async MJ_AIPromptRuns_ConfigurationIDArray(mjaiconfiguration_, { dataSources, userPayload, providers }, pubSub) {
|
|
4347
|
-
this.CheckUserReadPermissions('MJ: AI Prompt Runs', userPayload);
|
|
4348
|
-
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
4349
|
-
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
4350
|
-
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwAIPromptRuns] WHERE [ConfigurationID]='${mjaiconfiguration_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Prompt Runs', userPayload, EntityPermissionType.Read, 'AND');
|
|
4351
|
-
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
4352
|
-
const result = this.ArrayMapFieldNamesToCodeNames('MJ: AI Prompt Runs', rows);
|
|
4353
|
-
return result;
|
|
4354
|
-
}
|
|
4355
4355
|
async MJ_AIAgentRuns_ConfigurationIDArray(mjaiconfiguration_, { dataSources, userPayload, providers }, pubSub) {
|
|
4356
4356
|
this.CheckUserReadPermissions('MJ: AI Agent Runs', userPayload);
|
|
4357
4357
|
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
@@ -4430,32 +4430,32 @@ __decorate([
|
|
|
4430
4430
|
__metadata("design:returntype", Promise)
|
|
4431
4431
|
], MJAIConfigurationResolver.prototype, "MJ_AIAgentPrompts_ConfigurationIDArray", null);
|
|
4432
4432
|
__decorate([
|
|
4433
|
-
FieldResolver(() => [
|
|
4433
|
+
FieldResolver(() => [MJAIPromptRun_]),
|
|
4434
4434
|
__param(0, Root()),
|
|
4435
4435
|
__param(1, Ctx()),
|
|
4436
4436
|
__param(2, PubSub()),
|
|
4437
4437
|
__metadata("design:type", Function),
|
|
4438
4438
|
__metadata("design:paramtypes", [MJAIConfiguration_, Object, PubSubEngine]),
|
|
4439
4439
|
__metadata("design:returntype", Promise)
|
|
4440
|
-
], MJAIConfigurationResolver.prototype, "
|
|
4440
|
+
], MJAIConfigurationResolver.prototype, "MJ_AIPromptRuns_ConfigurationIDArray", null);
|
|
4441
4441
|
__decorate([
|
|
4442
|
-
FieldResolver(() => [
|
|
4442
|
+
FieldResolver(() => [MJAIPromptModel_]),
|
|
4443
4443
|
__param(0, Root()),
|
|
4444
4444
|
__param(1, Ctx()),
|
|
4445
4445
|
__param(2, PubSub()),
|
|
4446
4446
|
__metadata("design:type", Function),
|
|
4447
4447
|
__metadata("design:paramtypes", [MJAIConfiguration_, Object, PubSubEngine]),
|
|
4448
4448
|
__metadata("design:returntype", Promise)
|
|
4449
|
-
], MJAIConfigurationResolver.prototype, "
|
|
4449
|
+
], MJAIConfigurationResolver.prototype, "MJ_AIPromptModels_ConfigurationIDArray", null);
|
|
4450
4450
|
__decorate([
|
|
4451
|
-
FieldResolver(() => [
|
|
4451
|
+
FieldResolver(() => [MJAIResultCache_]),
|
|
4452
4452
|
__param(0, Root()),
|
|
4453
4453
|
__param(1, Ctx()),
|
|
4454
4454
|
__param(2, PubSub()),
|
|
4455
4455
|
__metadata("design:type", Function),
|
|
4456
4456
|
__metadata("design:paramtypes", [MJAIConfiguration_, Object, PubSubEngine]),
|
|
4457
4457
|
__metadata("design:returntype", Promise)
|
|
4458
|
-
], MJAIConfigurationResolver.prototype, "
|
|
4458
|
+
], MJAIConfigurationResolver.prototype, "AIResultCache_ConfigurationIDArray", null);
|
|
4459
4459
|
__decorate([
|
|
4460
4460
|
FieldResolver(() => [MJAIAgentRun_]),
|
|
4461
4461
|
__param(0, Root()),
|
|
@@ -4547,6 +4547,9 @@ let MJAIAgent_ = class MJAIAgent_ {
|
|
|
4547
4547
|
InjectExamples;
|
|
4548
4548
|
MaxExamplesToInject;
|
|
4549
4549
|
ExampleInjectionStrategy;
|
|
4550
|
+
IsRestricted;
|
|
4551
|
+
MessageMode;
|
|
4552
|
+
MaxMessages;
|
|
4550
4553
|
Parent;
|
|
4551
4554
|
ContextCompressionPrompt;
|
|
4552
4555
|
Type;
|
|
@@ -4799,6 +4802,19 @@ __decorate([
|
|
|
4799
4802
|
MaxLength(40),
|
|
4800
4803
|
__metadata("design:type", String)
|
|
4801
4804
|
], MJAIAgent_.prototype, "ExampleInjectionStrategy", void 0);
|
|
4805
|
+
__decorate([
|
|
4806
|
+
Field(() => Boolean, { description: `When true, agent is restricted to system/scheduled use only and hidden from user selection, Agent Manager, and MCP/A2A discovery.` }),
|
|
4807
|
+
__metadata("design:type", Boolean)
|
|
4808
|
+
], MJAIAgent_.prototype, "IsRestricted", void 0);
|
|
4809
|
+
__decorate([
|
|
4810
|
+
Field({ description: `Specifies how conversation messages are passed from parent agent to this child sub-agent (when this agent is a child via ParentID). Valid values: 'None' (fresh start - only context and task message, default), 'All' (all parent conversation history), 'Latest' (most recent MaxMessages messages), 'Bookend' (first 2 messages + most recent MaxMessages-2 messages with indicator between). Stored on child agent because each child has only one parent relationship.` }),
|
|
4811
|
+
MaxLength(100),
|
|
4812
|
+
__metadata("design:type", String)
|
|
4813
|
+
], MJAIAgent_.prototype, "MessageMode", void 0);
|
|
4814
|
+
__decorate([
|
|
4815
|
+
Field(() => Int, { nullable: true, description: `Maximum number of conversation messages to include when MessageMode is 'Latest' or 'Bookend'. NULL means no limit (ignored for 'None' and 'All' modes). Must be greater than 0 if specified. For 'Latest': keeps most recent N messages. For 'Bookend': keeps first 2 + most recent (N-2) messages.` }),
|
|
4816
|
+
__metadata("design:type", Number)
|
|
4817
|
+
], MJAIAgent_.prototype, "MaxMessages", void 0);
|
|
4802
4818
|
__decorate([
|
|
4803
4819
|
Field({ nullable: true }),
|
|
4804
4820
|
MaxLength(510),
|
|
@@ -4961,6 +4977,9 @@ let CreateMJAIAgentInput = class CreateMJAIAgentInput {
|
|
|
4961
4977
|
InjectExamples;
|
|
4962
4978
|
MaxExamplesToInject;
|
|
4963
4979
|
ExampleInjectionStrategy;
|
|
4980
|
+
IsRestricted;
|
|
4981
|
+
MessageMode;
|
|
4982
|
+
MaxMessages;
|
|
4964
4983
|
};
|
|
4965
4984
|
__decorate([
|
|
4966
4985
|
Field({ nullable: true }),
|
|
@@ -5150,6 +5169,18 @@ __decorate([
|
|
|
5150
5169
|
Field({ nullable: true }),
|
|
5151
5170
|
__metadata("design:type", String)
|
|
5152
5171
|
], CreateMJAIAgentInput.prototype, "ExampleInjectionStrategy", void 0);
|
|
5172
|
+
__decorate([
|
|
5173
|
+
Field(() => Boolean, { nullable: true }),
|
|
5174
|
+
__metadata("design:type", Boolean)
|
|
5175
|
+
], CreateMJAIAgentInput.prototype, "IsRestricted", void 0);
|
|
5176
|
+
__decorate([
|
|
5177
|
+
Field({ nullable: true }),
|
|
5178
|
+
__metadata("design:type", String)
|
|
5179
|
+
], CreateMJAIAgentInput.prototype, "MessageMode", void 0);
|
|
5180
|
+
__decorate([
|
|
5181
|
+
Field(() => Int, { nullable: true }),
|
|
5182
|
+
__metadata("design:type", Number)
|
|
5183
|
+
], CreateMJAIAgentInput.prototype, "MaxMessages", void 0);
|
|
5153
5184
|
CreateMJAIAgentInput = __decorate([
|
|
5154
5185
|
InputType()
|
|
5155
5186
|
], CreateMJAIAgentInput);
|
|
@@ -5202,6 +5233,9 @@ let UpdateMJAIAgentInput = class UpdateMJAIAgentInput {
|
|
|
5202
5233
|
InjectExamples;
|
|
5203
5234
|
MaxExamplesToInject;
|
|
5204
5235
|
ExampleInjectionStrategy;
|
|
5236
|
+
IsRestricted;
|
|
5237
|
+
MessageMode;
|
|
5238
|
+
MaxMessages;
|
|
5205
5239
|
OldValues___;
|
|
5206
5240
|
};
|
|
5207
5241
|
__decorate([
|
|
@@ -5392,6 +5426,18 @@ __decorate([
|
|
|
5392
5426
|
Field({ nullable: true }),
|
|
5393
5427
|
__metadata("design:type", String)
|
|
5394
5428
|
], UpdateMJAIAgentInput.prototype, "ExampleInjectionStrategy", void 0);
|
|
5429
|
+
__decorate([
|
|
5430
|
+
Field(() => Boolean, { nullable: true }),
|
|
5431
|
+
__metadata("design:type", Boolean)
|
|
5432
|
+
], UpdateMJAIAgentInput.prototype, "IsRestricted", void 0);
|
|
5433
|
+
__decorate([
|
|
5434
|
+
Field({ nullable: true }),
|
|
5435
|
+
__metadata("design:type", String)
|
|
5436
|
+
], UpdateMJAIAgentInput.prototype, "MessageMode", void 0);
|
|
5437
|
+
__decorate([
|
|
5438
|
+
Field(() => Int, { nullable: true }),
|
|
5439
|
+
__metadata("design:type", Number)
|
|
5440
|
+
], UpdateMJAIAgentInput.prototype, "MaxMessages", void 0);
|
|
5395
5441
|
__decorate([
|
|
5396
5442
|
Field(() => [KeyValuePairInput], { nullable: true }),
|
|
5397
5443
|
__metadata("design:type", Array)
|
|
@@ -7668,11 +7714,14 @@ let MJAIAgentNote_ = class MJAIAgentNote_ {
|
|
|
7668
7714
|
SourceConversationDetailID;
|
|
7669
7715
|
SourceAIAgentRunID;
|
|
7670
7716
|
CompanyID;
|
|
7717
|
+
EmbeddingVector;
|
|
7718
|
+
EmbeddingModelID;
|
|
7671
7719
|
Agent;
|
|
7672
7720
|
AgentNoteType;
|
|
7673
7721
|
User;
|
|
7674
7722
|
SourceConversation;
|
|
7675
7723
|
Company;
|
|
7724
|
+
EmbeddingModel;
|
|
7676
7725
|
};
|
|
7677
7726
|
__decorate([
|
|
7678
7727
|
Field(),
|
|
@@ -7746,6 +7795,15 @@ __decorate([
|
|
|
7746
7795
|
MaxLength(16),
|
|
7747
7796
|
__metadata("design:type", String)
|
|
7748
7797
|
], MJAIAgentNote_.prototype, "CompanyID", void 0);
|
|
7798
|
+
__decorate([
|
|
7799
|
+
Field({ nullable: true, description: `JSON array of embedding vector for semantic search on Note field. Auto-generated when Note changes.` }),
|
|
7800
|
+
__metadata("design:type", String)
|
|
7801
|
+
], MJAIAgentNote_.prototype, "EmbeddingVector", void 0);
|
|
7802
|
+
__decorate([
|
|
7803
|
+
Field({ nullable: true, description: `Reference to the AI model used to generate the embedding vector.` }),
|
|
7804
|
+
MaxLength(16),
|
|
7805
|
+
__metadata("design:type", String)
|
|
7806
|
+
], MJAIAgentNote_.prototype, "EmbeddingModelID", void 0);
|
|
7749
7807
|
__decorate([
|
|
7750
7808
|
Field({ nullable: true }),
|
|
7751
7809
|
MaxLength(510),
|
|
@@ -7771,6 +7829,11 @@ __decorate([
|
|
|
7771
7829
|
MaxLength(100),
|
|
7772
7830
|
__metadata("design:type", String)
|
|
7773
7831
|
], MJAIAgentNote_.prototype, "Company", void 0);
|
|
7832
|
+
__decorate([
|
|
7833
|
+
Field({ nullable: true }),
|
|
7834
|
+
MaxLength(100),
|
|
7835
|
+
__metadata("design:type", String)
|
|
7836
|
+
], MJAIAgentNote_.prototype, "EmbeddingModel", void 0);
|
|
7774
7837
|
MJAIAgentNote_ = __decorate([
|
|
7775
7838
|
ObjectType({ description: `Stores notes, observations, and learnings for AI agents with multi-dimensional scoping (Agent, User, company). Scoping is determined by which FK fields are populated: all NULL = global, AgentID only = agent-specific, UserID only = user-specific across all agents, etc.` })
|
|
7776
7839
|
], MJAIAgentNote_);
|
|
@@ -7789,6 +7852,8 @@ let CreateMJAIAgentNoteInput = class CreateMJAIAgentNoteInput {
|
|
|
7789
7852
|
SourceConversationDetailID;
|
|
7790
7853
|
SourceAIAgentRunID;
|
|
7791
7854
|
CompanyID;
|
|
7855
|
+
EmbeddingVector;
|
|
7856
|
+
EmbeddingModelID;
|
|
7792
7857
|
};
|
|
7793
7858
|
__decorate([
|
|
7794
7859
|
Field({ nullable: true }),
|
|
@@ -7842,6 +7907,14 @@ __decorate([
|
|
|
7842
7907
|
Field({ nullable: true }),
|
|
7843
7908
|
__metadata("design:type", String)
|
|
7844
7909
|
], CreateMJAIAgentNoteInput.prototype, "CompanyID", void 0);
|
|
7910
|
+
__decorate([
|
|
7911
|
+
Field({ nullable: true }),
|
|
7912
|
+
__metadata("design:type", String)
|
|
7913
|
+
], CreateMJAIAgentNoteInput.prototype, "EmbeddingVector", void 0);
|
|
7914
|
+
__decorate([
|
|
7915
|
+
Field({ nullable: true }),
|
|
7916
|
+
__metadata("design:type", String)
|
|
7917
|
+
], CreateMJAIAgentNoteInput.prototype, "EmbeddingModelID", void 0);
|
|
7845
7918
|
CreateMJAIAgentNoteInput = __decorate([
|
|
7846
7919
|
InputType()
|
|
7847
7920
|
], CreateMJAIAgentNoteInput);
|
|
@@ -7860,6 +7933,8 @@ let UpdateMJAIAgentNoteInput = class UpdateMJAIAgentNoteInput {
|
|
|
7860
7933
|
SourceConversationDetailID;
|
|
7861
7934
|
SourceAIAgentRunID;
|
|
7862
7935
|
CompanyID;
|
|
7936
|
+
EmbeddingVector;
|
|
7937
|
+
EmbeddingModelID;
|
|
7863
7938
|
OldValues___;
|
|
7864
7939
|
};
|
|
7865
7940
|
__decorate([
|
|
@@ -7914,6 +7989,14 @@ __decorate([
|
|
|
7914
7989
|
Field({ nullable: true }),
|
|
7915
7990
|
__metadata("design:type", String)
|
|
7916
7991
|
], UpdateMJAIAgentNoteInput.prototype, "CompanyID", void 0);
|
|
7992
|
+
__decorate([
|
|
7993
|
+
Field({ nullable: true }),
|
|
7994
|
+
__metadata("design:type", String)
|
|
7995
|
+
], UpdateMJAIAgentNoteInput.prototype, "EmbeddingVector", void 0);
|
|
7996
|
+
__decorate([
|
|
7997
|
+
Field({ nullable: true }),
|
|
7998
|
+
__metadata("design:type", String)
|
|
7999
|
+
], UpdateMJAIAgentNoteInput.prototype, "EmbeddingModelID", void 0);
|
|
7917
8000
|
__decorate([
|
|
7918
8001
|
Field(() => [KeyValuePairInput], { nullable: true }),
|
|
7919
8002
|
__metadata("design:type", Array)
|
|
@@ -9441,12 +9524,12 @@ export { MJTaskDependencyResolver };
|
|
|
9441
9524
|
let MJCollectionArtifact_ = class MJCollectionArtifact_ {
|
|
9442
9525
|
ID;
|
|
9443
9526
|
CollectionID;
|
|
9444
|
-
ArtifactID;
|
|
9445
9527
|
Sequence;
|
|
9446
9528
|
_mj__CreatedAt;
|
|
9447
9529
|
_mj__UpdatedAt;
|
|
9530
|
+
ArtifactVersionID;
|
|
9448
9531
|
Collection;
|
|
9449
|
-
|
|
9532
|
+
ArtifactVersion;
|
|
9450
9533
|
};
|
|
9451
9534
|
__decorate([
|
|
9452
9535
|
Field(),
|
|
@@ -9458,11 +9541,6 @@ __decorate([
|
|
|
9458
9541
|
MaxLength(16),
|
|
9459
9542
|
__metadata("design:type", String)
|
|
9460
9543
|
], MJCollectionArtifact_.prototype, "CollectionID", void 0);
|
|
9461
|
-
__decorate([
|
|
9462
|
-
Field(),
|
|
9463
|
-
MaxLength(16),
|
|
9464
|
-
__metadata("design:type", String)
|
|
9465
|
-
], MJCollectionArtifact_.prototype, "ArtifactID", void 0);
|
|
9466
9544
|
__decorate([
|
|
9467
9545
|
Field(() => Int, { description: `Sequence number for ordering artifacts within a collection` }),
|
|
9468
9546
|
__metadata("design:type", Number)
|
|
@@ -9477,25 +9555,30 @@ __decorate([
|
|
|
9477
9555
|
MaxLength(10),
|
|
9478
9556
|
__metadata("design:type", Date)
|
|
9479
9557
|
], MJCollectionArtifact_.prototype, "_mj__UpdatedAt", void 0);
|
|
9558
|
+
__decorate([
|
|
9559
|
+
Field({ description: `Required. Specific version of the artifact saved to this collection. Collections store version-specific artifacts to enable proper version tracking and Links tab filtering.` }),
|
|
9560
|
+
MaxLength(16),
|
|
9561
|
+
__metadata("design:type", String)
|
|
9562
|
+
], MJCollectionArtifact_.prototype, "ArtifactVersionID", void 0);
|
|
9480
9563
|
__decorate([
|
|
9481
9564
|
Field(),
|
|
9482
9565
|
MaxLength(510),
|
|
9483
9566
|
__metadata("design:type", String)
|
|
9484
9567
|
], MJCollectionArtifact_.prototype, "Collection", void 0);
|
|
9485
9568
|
__decorate([
|
|
9486
|
-
Field(),
|
|
9569
|
+
Field({ nullable: true }),
|
|
9487
9570
|
MaxLength(510),
|
|
9488
9571
|
__metadata("design:type", String)
|
|
9489
|
-
], MJCollectionArtifact_.prototype, "
|
|
9572
|
+
], MJCollectionArtifact_.prototype, "ArtifactVersion", void 0);
|
|
9490
9573
|
MJCollectionArtifact_ = __decorate([
|
|
9491
|
-
ObjectType({ description: `
|
|
9574
|
+
ObjectType({ description: `Links collections to specific artifact versions. Each collection can contain multiple versions of the same artifact.` })
|
|
9492
9575
|
], MJCollectionArtifact_);
|
|
9493
9576
|
export { MJCollectionArtifact_ };
|
|
9494
9577
|
let CreateMJCollectionArtifactInput = class CreateMJCollectionArtifactInput {
|
|
9495
9578
|
ID;
|
|
9496
9579
|
CollectionID;
|
|
9497
|
-
ArtifactID;
|
|
9498
9580
|
Sequence;
|
|
9581
|
+
ArtifactVersionID;
|
|
9499
9582
|
};
|
|
9500
9583
|
__decorate([
|
|
9501
9584
|
Field({ nullable: true }),
|
|
@@ -9505,14 +9588,14 @@ __decorate([
|
|
|
9505
9588
|
Field({ nullable: true }),
|
|
9506
9589
|
__metadata("design:type", String)
|
|
9507
9590
|
], CreateMJCollectionArtifactInput.prototype, "CollectionID", void 0);
|
|
9508
|
-
__decorate([
|
|
9509
|
-
Field({ nullable: true }),
|
|
9510
|
-
__metadata("design:type", String)
|
|
9511
|
-
], CreateMJCollectionArtifactInput.prototype, "ArtifactID", void 0);
|
|
9512
9591
|
__decorate([
|
|
9513
9592
|
Field(() => Int, { nullable: true }),
|
|
9514
9593
|
__metadata("design:type", Number)
|
|
9515
9594
|
], CreateMJCollectionArtifactInput.prototype, "Sequence", void 0);
|
|
9595
|
+
__decorate([
|
|
9596
|
+
Field({ nullable: true }),
|
|
9597
|
+
__metadata("design:type", String)
|
|
9598
|
+
], CreateMJCollectionArtifactInput.prototype, "ArtifactVersionID", void 0);
|
|
9516
9599
|
CreateMJCollectionArtifactInput = __decorate([
|
|
9517
9600
|
InputType()
|
|
9518
9601
|
], CreateMJCollectionArtifactInput);
|
|
@@ -9520,8 +9603,8 @@ export { CreateMJCollectionArtifactInput };
|
|
|
9520
9603
|
let UpdateMJCollectionArtifactInput = class UpdateMJCollectionArtifactInput {
|
|
9521
9604
|
ID;
|
|
9522
9605
|
CollectionID;
|
|
9523
|
-
ArtifactID;
|
|
9524
9606
|
Sequence;
|
|
9607
|
+
ArtifactVersionID;
|
|
9525
9608
|
OldValues___;
|
|
9526
9609
|
};
|
|
9527
9610
|
__decorate([
|
|
@@ -9532,14 +9615,14 @@ __decorate([
|
|
|
9532
9615
|
Field({ nullable: true }),
|
|
9533
9616
|
__metadata("design:type", String)
|
|
9534
9617
|
], UpdateMJCollectionArtifactInput.prototype, "CollectionID", void 0);
|
|
9535
|
-
__decorate([
|
|
9536
|
-
Field({ nullable: true }),
|
|
9537
|
-
__metadata("design:type", String)
|
|
9538
|
-
], UpdateMJCollectionArtifactInput.prototype, "ArtifactID", void 0);
|
|
9539
9618
|
__decorate([
|
|
9540
9619
|
Field(() => Int, { nullable: true }),
|
|
9541
9620
|
__metadata("design:type", Number)
|
|
9542
9621
|
], UpdateMJCollectionArtifactInput.prototype, "Sequence", void 0);
|
|
9622
|
+
__decorate([
|
|
9623
|
+
Field({ nullable: true }),
|
|
9624
|
+
__metadata("design:type", String)
|
|
9625
|
+
], UpdateMJCollectionArtifactInput.prototype, "ArtifactVersionID", void 0);
|
|
9543
9626
|
__decorate([
|
|
9544
9627
|
Field(() => [KeyValuePairInput], { nullable: true }),
|
|
9545
9628
|
__metadata("design:type", Array)
|
|
@@ -19649,6 +19732,8 @@ let MJUser_ = class MJUser_ {
|
|
|
19649
19732
|
MJ_ScheduledJobRuns_ExecutedByUserIDArray;
|
|
19650
19733
|
MJ_ScheduledJobs_NotifyUserIDArray;
|
|
19651
19734
|
MJ_ArtifactPermissions_UserIDArray;
|
|
19735
|
+
MJ_ArtifactUses_UserIDArray;
|
|
19736
|
+
MJ_ConversationDetailRatings_UserIDArray;
|
|
19652
19737
|
ResourcePermissions_UserIDArray;
|
|
19653
19738
|
AIAgentRequests_RequestForUserIDArray;
|
|
19654
19739
|
ConversationDetails_UserIDArray;
|
|
@@ -19945,6 +20030,14 @@ __decorate([
|
|
|
19945
20030
|
Field(() => [MJArtifactPermission_]),
|
|
19946
20031
|
__metadata("design:type", Array)
|
|
19947
20032
|
], MJUser_.prototype, "MJ_ArtifactPermissions_UserIDArray", void 0);
|
|
20033
|
+
__decorate([
|
|
20034
|
+
Field(() => [MJArtifactUse_]),
|
|
20035
|
+
__metadata("design:type", Array)
|
|
20036
|
+
], MJUser_.prototype, "MJ_ArtifactUses_UserIDArray", void 0);
|
|
20037
|
+
__decorate([
|
|
20038
|
+
Field(() => [MJConversationDetailRating_]),
|
|
20039
|
+
__metadata("design:type", Array)
|
|
20040
|
+
], MJUser_.prototype, "MJ_ConversationDetailRatings_UserIDArray", void 0);
|
|
19948
20041
|
__decorate([
|
|
19949
20042
|
Field(() => [MJResourcePermission_]),
|
|
19950
20043
|
__metadata("design:type", Array)
|
|
@@ -20626,6 +20719,24 @@ let MJUserResolverBase = class MJUserResolverBase extends ResolverBase {
|
|
|
20626
20719
|
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Artifact Permissions', rows);
|
|
20627
20720
|
return result;
|
|
20628
20721
|
}
|
|
20722
|
+
async MJ_ArtifactUses_UserIDArray(mjuser_, { dataSources, userPayload, providers }, pubSub) {
|
|
20723
|
+
this.CheckUserReadPermissions('MJ: Artifact Uses', userPayload);
|
|
20724
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
20725
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
20726
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwArtifactUses] WHERE [UserID]='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Artifact Uses', userPayload, EntityPermissionType.Read, 'AND');
|
|
20727
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
20728
|
+
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Artifact Uses', rows);
|
|
20729
|
+
return result;
|
|
20730
|
+
}
|
|
20731
|
+
async MJ_ConversationDetailRatings_UserIDArray(mjuser_, { dataSources, userPayload, providers }, pubSub) {
|
|
20732
|
+
this.CheckUserReadPermissions('MJ: Conversation Detail Ratings', userPayload);
|
|
20733
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
20734
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
20735
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwConversationDetailRatings] WHERE [UserID]='${mjuser_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Conversation Detail Ratings', userPayload, EntityPermissionType.Read, 'AND');
|
|
20736
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
20737
|
+
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Conversation Detail Ratings', rows);
|
|
20738
|
+
return result;
|
|
20739
|
+
}
|
|
20629
20740
|
async ResourcePermissions_UserIDArray(mjuser_, { dataSources, userPayload, providers }, pubSub) {
|
|
20630
20741
|
this.CheckUserReadPermissions('Resource Permissions', userPayload);
|
|
20631
20742
|
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
@@ -21206,6 +21317,24 @@ __decorate([
|
|
|
21206
21317
|
__metadata("design:paramtypes", [MJUser_, Object, PubSubEngine]),
|
|
21207
21318
|
__metadata("design:returntype", Promise)
|
|
21208
21319
|
], MJUserResolverBase.prototype, "MJ_ArtifactPermissions_UserIDArray", null);
|
|
21320
|
+
__decorate([
|
|
21321
|
+
FieldResolver(() => [MJArtifactUse_]),
|
|
21322
|
+
__param(0, Root()),
|
|
21323
|
+
__param(1, Ctx()),
|
|
21324
|
+
__param(2, PubSub()),
|
|
21325
|
+
__metadata("design:type", Function),
|
|
21326
|
+
__metadata("design:paramtypes", [MJUser_, Object, PubSubEngine]),
|
|
21327
|
+
__metadata("design:returntype", Promise)
|
|
21328
|
+
], MJUserResolverBase.prototype, "MJ_ArtifactUses_UserIDArray", null);
|
|
21329
|
+
__decorate([
|
|
21330
|
+
FieldResolver(() => [MJConversationDetailRating_]),
|
|
21331
|
+
__param(0, Root()),
|
|
21332
|
+
__param(1, Ctx()),
|
|
21333
|
+
__param(2, PubSub()),
|
|
21334
|
+
__metadata("design:type", Function),
|
|
21335
|
+
__metadata("design:paramtypes", [MJUser_, Object, PubSubEngine]),
|
|
21336
|
+
__metadata("design:returntype", Promise)
|
|
21337
|
+
], MJUserResolverBase.prototype, "MJ_ConversationDetailRatings_UserIDArray", null);
|
|
21209
21338
|
__decorate([
|
|
21210
21339
|
FieldResolver(() => [MJResourcePermission_]),
|
|
21211
21340
|
__param(0, Root()),
|
|
@@ -30737,6 +30866,8 @@ let MJAIModel_ = class MJAIModel_ {
|
|
|
30737
30866
|
EntityAIActions_AIModelIDArray;
|
|
30738
30867
|
ContentTypes_AIModelIDArray;
|
|
30739
30868
|
AIResultCache_AIModelIDArray;
|
|
30869
|
+
AIAgentNotes_EmbeddingModelIDArray;
|
|
30870
|
+
MJ_AIAgentExamples_EmbeddingModelIDArray;
|
|
30740
30871
|
AIAgentModels_ModelIDArray;
|
|
30741
30872
|
MJ_AIModelVendors_ModelIDArray;
|
|
30742
30873
|
GeneratedCodes_GeneratedByModelIDArray;
|
|
@@ -30861,6 +30992,14 @@ __decorate([
|
|
|
30861
30992
|
Field(() => [MJAIResultCache_]),
|
|
30862
30993
|
__metadata("design:type", Array)
|
|
30863
30994
|
], MJAIModel_.prototype, "AIResultCache_AIModelIDArray", void 0);
|
|
30995
|
+
__decorate([
|
|
30996
|
+
Field(() => [MJAIAgentNote_]),
|
|
30997
|
+
__metadata("design:type", Array)
|
|
30998
|
+
], MJAIModel_.prototype, "AIAgentNotes_EmbeddingModelIDArray", void 0);
|
|
30999
|
+
__decorate([
|
|
31000
|
+
Field(() => [MJAIAgentExample_]),
|
|
31001
|
+
__metadata("design:type", Array)
|
|
31002
|
+
], MJAIModel_.prototype, "MJ_AIAgentExamples_EmbeddingModelIDArray", void 0);
|
|
30864
31003
|
__decorate([
|
|
30865
31004
|
Field(() => [MJAIAgentModel_]),
|
|
30866
31005
|
__metadata("design:type", Array)
|
|
@@ -31140,6 +31279,24 @@ let MJAIModelResolver = class MJAIModelResolver extends ResolverBase {
|
|
|
31140
31279
|
const result = this.ArrayMapFieldNamesToCodeNames('AI Result Cache', rows);
|
|
31141
31280
|
return result;
|
|
31142
31281
|
}
|
|
31282
|
+
async AIAgentNotes_EmbeddingModelIDArray(mjaimodel_, { dataSources, userPayload, providers }, pubSub) {
|
|
31283
|
+
this.CheckUserReadPermissions('AI Agent Notes', userPayload);
|
|
31284
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
31285
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
31286
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwAIAgentNotes] WHERE [EmbeddingModelID]='${mjaimodel_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'AI Agent Notes', userPayload, EntityPermissionType.Read, 'AND');
|
|
31287
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
31288
|
+
const result = this.ArrayMapFieldNamesToCodeNames('AI Agent Notes', rows);
|
|
31289
|
+
return result;
|
|
31290
|
+
}
|
|
31291
|
+
async MJ_AIAgentExamples_EmbeddingModelIDArray(mjaimodel_, { dataSources, userPayload, providers }, pubSub) {
|
|
31292
|
+
this.CheckUserReadPermissions('MJ: AI Agent Examples', userPayload);
|
|
31293
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
31294
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
31295
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwAIAgentExamples] WHERE [EmbeddingModelID]='${mjaimodel_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: AI Agent Examples', userPayload, EntityPermissionType.Read, 'AND');
|
|
31296
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
31297
|
+
const result = this.ArrayMapFieldNamesToCodeNames('MJ: AI Agent Examples', rows);
|
|
31298
|
+
return result;
|
|
31299
|
+
}
|
|
31143
31300
|
async AIAgentModels_ModelIDArray(mjaimodel_, { dataSources, userPayload, providers }, pubSub) {
|
|
31144
31301
|
this.CheckUserReadPermissions('AI Agent Models', userPayload);
|
|
31145
31302
|
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
@@ -31333,6 +31490,24 @@ __decorate([
|
|
|
31333
31490
|
__metadata("design:paramtypes", [MJAIModel_, Object, PubSubEngine]),
|
|
31334
31491
|
__metadata("design:returntype", Promise)
|
|
31335
31492
|
], MJAIModelResolver.prototype, "AIResultCache_AIModelIDArray", null);
|
|
31493
|
+
__decorate([
|
|
31494
|
+
FieldResolver(() => [MJAIAgentNote_]),
|
|
31495
|
+
__param(0, Root()),
|
|
31496
|
+
__param(1, Ctx()),
|
|
31497
|
+
__param(2, PubSub()),
|
|
31498
|
+
__metadata("design:type", Function),
|
|
31499
|
+
__metadata("design:paramtypes", [MJAIModel_, Object, PubSubEngine]),
|
|
31500
|
+
__metadata("design:returntype", Promise)
|
|
31501
|
+
], MJAIModelResolver.prototype, "AIAgentNotes_EmbeddingModelIDArray", null);
|
|
31502
|
+
__decorate([
|
|
31503
|
+
FieldResolver(() => [MJAIAgentExample_]),
|
|
31504
|
+
__param(0, Root()),
|
|
31505
|
+
__param(1, Ctx()),
|
|
31506
|
+
__param(2, PubSub()),
|
|
31507
|
+
__metadata("design:type", Function),
|
|
31508
|
+
__metadata("design:paramtypes", [MJAIModel_, Object, PubSubEngine]),
|
|
31509
|
+
__metadata("design:returntype", Promise)
|
|
31510
|
+
], MJAIModelResolver.prototype, "MJ_AIAgentExamples_EmbeddingModelIDArray", null);
|
|
31336
31511
|
__decorate([
|
|
31337
31512
|
FieldResolver(() => [MJAIAgentModel_]),
|
|
31338
31513
|
__param(0, Root()),
|
|
@@ -38134,6 +38309,7 @@ let MJConversationDetail_ = class MJConversationDetail_ {
|
|
|
38134
38309
|
RootParentID;
|
|
38135
38310
|
Reports_ConversationDetailIDArray;
|
|
38136
38311
|
MJ_ConversationDetailArtifacts_ConversationDetailIDArray;
|
|
38312
|
+
MJ_ConversationDetailRatings_ConversationDetailIDArray;
|
|
38137
38313
|
AIAgentNotes_SourceConversationDetailIDArray;
|
|
38138
38314
|
MJ_AIAgentRuns_ConversationDetailIDArray;
|
|
38139
38315
|
ConversationDetails_ParentIDArray;
|
|
@@ -38273,6 +38449,10 @@ __decorate([
|
|
|
38273
38449
|
Field(() => [MJConversationDetailArtifact_]),
|
|
38274
38450
|
__metadata("design:type", Array)
|
|
38275
38451
|
], MJConversationDetail_.prototype, "MJ_ConversationDetailArtifacts_ConversationDetailIDArray", void 0);
|
|
38452
|
+
__decorate([
|
|
38453
|
+
Field(() => [MJConversationDetailRating_]),
|
|
38454
|
+
__metadata("design:type", Array)
|
|
38455
|
+
], MJConversationDetail_.prototype, "MJ_ConversationDetailRatings_ConversationDetailIDArray", void 0);
|
|
38276
38456
|
__decorate([
|
|
38277
38457
|
Field(() => [MJAIAgentNote_]),
|
|
38278
38458
|
__metadata("design:type", Array)
|
|
@@ -38596,6 +38776,15 @@ let MJConversationDetailResolver = class MJConversationDetailResolver extends Re
|
|
|
38596
38776
|
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Conversation Detail Artifacts', rows);
|
|
38597
38777
|
return result;
|
|
38598
38778
|
}
|
|
38779
|
+
async MJ_ConversationDetailRatings_ConversationDetailIDArray(mjconversationdetail_, { dataSources, userPayload, providers }, pubSub) {
|
|
38780
|
+
this.CheckUserReadPermissions('MJ: Conversation Detail Ratings', userPayload);
|
|
38781
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
38782
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
38783
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwConversationDetailRatings] WHERE [ConversationDetailID]='${mjconversationdetail_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Conversation Detail Ratings', userPayload, EntityPermissionType.Read, 'AND');
|
|
38784
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
38785
|
+
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Conversation Detail Ratings', rows);
|
|
38786
|
+
return result;
|
|
38787
|
+
}
|
|
38599
38788
|
async AIAgentNotes_SourceConversationDetailIDArray(mjconversationdetail_, { dataSources, userPayload, providers }, pubSub) {
|
|
38600
38789
|
this.CheckUserReadPermissions('AI Agent Notes', userPayload);
|
|
38601
38790
|
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
@@ -38709,6 +38898,15 @@ __decorate([
|
|
|
38709
38898
|
__metadata("design:paramtypes", [MJConversationDetail_, Object, PubSubEngine]),
|
|
38710
38899
|
__metadata("design:returntype", Promise)
|
|
38711
38900
|
], MJConversationDetailResolver.prototype, "MJ_ConversationDetailArtifacts_ConversationDetailIDArray", null);
|
|
38901
|
+
__decorate([
|
|
38902
|
+
FieldResolver(() => [MJConversationDetailRating_]),
|
|
38903
|
+
__param(0, Root()),
|
|
38904
|
+
__param(1, Ctx()),
|
|
38905
|
+
__param(2, PubSub()),
|
|
38906
|
+
__metadata("design:type", Function),
|
|
38907
|
+
__metadata("design:paramtypes", [MJConversationDetail_, Object, PubSubEngine]),
|
|
38908
|
+
__metadata("design:returntype", Promise)
|
|
38909
|
+
], MJConversationDetailResolver.prototype, "MJ_ConversationDetailRatings_ConversationDetailIDArray", null);
|
|
38712
38910
|
__decorate([
|
|
38713
38911
|
FieldResolver(() => [MJAIAgentNote_]),
|
|
38714
38912
|
__param(0, Root()),
|
|
@@ -65332,6 +65530,278 @@ MJAccessControlRuleResolver = __decorate([
|
|
|
65332
65530
|
Resolver(MJAccessControlRule_)
|
|
65333
65531
|
], MJAccessControlRuleResolver);
|
|
65334
65532
|
export { MJAccessControlRuleResolver };
|
|
65533
|
+
let MJArtifactUse_ = class MJArtifactUse_ {
|
|
65534
|
+
ID;
|
|
65535
|
+
ArtifactVersionID;
|
|
65536
|
+
UserID;
|
|
65537
|
+
UsageType;
|
|
65538
|
+
UsageContext;
|
|
65539
|
+
_mj__CreatedAt;
|
|
65540
|
+
_mj__UpdatedAt;
|
|
65541
|
+
ArtifactVersion;
|
|
65542
|
+
User;
|
|
65543
|
+
};
|
|
65544
|
+
__decorate([
|
|
65545
|
+
Field(),
|
|
65546
|
+
MaxLength(16),
|
|
65547
|
+
__metadata("design:type", String)
|
|
65548
|
+
], MJArtifactUse_.prototype, "ID", void 0);
|
|
65549
|
+
__decorate([
|
|
65550
|
+
Field({ description: `The specific version of the artifact being used.` }),
|
|
65551
|
+
MaxLength(16),
|
|
65552
|
+
__metadata("design:type", String)
|
|
65553
|
+
], MJArtifactUse_.prototype, "ArtifactVersionID", void 0);
|
|
65554
|
+
__decorate([
|
|
65555
|
+
Field({ description: `The user performing the action.` }),
|
|
65556
|
+
MaxLength(16),
|
|
65557
|
+
__metadata("design:type", String)
|
|
65558
|
+
], MJArtifactUse_.prototype, "UserID", void 0);
|
|
65559
|
+
__decorate([
|
|
65560
|
+
Field({ description: `Type of usage: Viewed (artifact displayed), Opened (artifact accessed), Shared (artifact shared with others), Saved (artifact bookmarked), or Exported (artifact downloaded).` }),
|
|
65561
|
+
MaxLength(40),
|
|
65562
|
+
__metadata("design:type", String)
|
|
65563
|
+
], MJArtifactUse_.prototype, "UsageType", void 0);
|
|
65564
|
+
__decorate([
|
|
65565
|
+
Field({ nullable: true, description: `Optional JSON context with additional metadata about the usage event (e.g., source page, referrer, device info).` }),
|
|
65566
|
+
__metadata("design:type", String)
|
|
65567
|
+
], MJArtifactUse_.prototype, "UsageContext", void 0);
|
|
65568
|
+
__decorate([
|
|
65569
|
+
Field(),
|
|
65570
|
+
MaxLength(10),
|
|
65571
|
+
__metadata("design:type", Date)
|
|
65572
|
+
], MJArtifactUse_.prototype, "_mj__CreatedAt", void 0);
|
|
65573
|
+
__decorate([
|
|
65574
|
+
Field(),
|
|
65575
|
+
MaxLength(10),
|
|
65576
|
+
__metadata("design:type", Date)
|
|
65577
|
+
], MJArtifactUse_.prototype, "_mj__UpdatedAt", void 0);
|
|
65578
|
+
__decorate([
|
|
65579
|
+
Field({ nullable: true }),
|
|
65580
|
+
MaxLength(510),
|
|
65581
|
+
__metadata("design:type", String)
|
|
65582
|
+
], MJArtifactUse_.prototype, "ArtifactVersion", void 0);
|
|
65583
|
+
__decorate([
|
|
65584
|
+
Field(),
|
|
65585
|
+
MaxLength(200),
|
|
65586
|
+
__metadata("design:type", String)
|
|
65587
|
+
], MJArtifactUse_.prototype, "User", void 0);
|
|
65588
|
+
MJArtifactUse_ = __decorate([
|
|
65589
|
+
ObjectType({ description: `Audit trail of artifact usage for security and analytics. Tracks each time an artifact is viewed, opened, shared, saved, or exported by users.` })
|
|
65590
|
+
], MJArtifactUse_);
|
|
65591
|
+
export { MJArtifactUse_ };
|
|
65592
|
+
let CreateMJArtifactUseInput = class CreateMJArtifactUseInput {
|
|
65593
|
+
ID;
|
|
65594
|
+
ArtifactVersionID;
|
|
65595
|
+
UserID;
|
|
65596
|
+
UsageType;
|
|
65597
|
+
UsageContext;
|
|
65598
|
+
};
|
|
65599
|
+
__decorate([
|
|
65600
|
+
Field({ nullable: true }),
|
|
65601
|
+
__metadata("design:type", String)
|
|
65602
|
+
], CreateMJArtifactUseInput.prototype, "ID", void 0);
|
|
65603
|
+
__decorate([
|
|
65604
|
+
Field({ nullable: true }),
|
|
65605
|
+
__metadata("design:type", String)
|
|
65606
|
+
], CreateMJArtifactUseInput.prototype, "ArtifactVersionID", void 0);
|
|
65607
|
+
__decorate([
|
|
65608
|
+
Field({ nullable: true }),
|
|
65609
|
+
__metadata("design:type", String)
|
|
65610
|
+
], CreateMJArtifactUseInput.prototype, "UserID", void 0);
|
|
65611
|
+
__decorate([
|
|
65612
|
+
Field({ nullable: true }),
|
|
65613
|
+
__metadata("design:type", String)
|
|
65614
|
+
], CreateMJArtifactUseInput.prototype, "UsageType", void 0);
|
|
65615
|
+
__decorate([
|
|
65616
|
+
Field({ nullable: true }),
|
|
65617
|
+
__metadata("design:type", String)
|
|
65618
|
+
], CreateMJArtifactUseInput.prototype, "UsageContext", void 0);
|
|
65619
|
+
CreateMJArtifactUseInput = __decorate([
|
|
65620
|
+
InputType()
|
|
65621
|
+
], CreateMJArtifactUseInput);
|
|
65622
|
+
export { CreateMJArtifactUseInput };
|
|
65623
|
+
let UpdateMJArtifactUseInput = class UpdateMJArtifactUseInput {
|
|
65624
|
+
ID;
|
|
65625
|
+
ArtifactVersionID;
|
|
65626
|
+
UserID;
|
|
65627
|
+
UsageType;
|
|
65628
|
+
UsageContext;
|
|
65629
|
+
OldValues___;
|
|
65630
|
+
};
|
|
65631
|
+
__decorate([
|
|
65632
|
+
Field(),
|
|
65633
|
+
__metadata("design:type", String)
|
|
65634
|
+
], UpdateMJArtifactUseInput.prototype, "ID", void 0);
|
|
65635
|
+
__decorate([
|
|
65636
|
+
Field({ nullable: true }),
|
|
65637
|
+
__metadata("design:type", String)
|
|
65638
|
+
], UpdateMJArtifactUseInput.prototype, "ArtifactVersionID", void 0);
|
|
65639
|
+
__decorate([
|
|
65640
|
+
Field({ nullable: true }),
|
|
65641
|
+
__metadata("design:type", String)
|
|
65642
|
+
], UpdateMJArtifactUseInput.prototype, "UserID", void 0);
|
|
65643
|
+
__decorate([
|
|
65644
|
+
Field({ nullable: true }),
|
|
65645
|
+
__metadata("design:type", String)
|
|
65646
|
+
], UpdateMJArtifactUseInput.prototype, "UsageType", void 0);
|
|
65647
|
+
__decorate([
|
|
65648
|
+
Field({ nullable: true }),
|
|
65649
|
+
__metadata("design:type", String)
|
|
65650
|
+
], UpdateMJArtifactUseInput.prototype, "UsageContext", void 0);
|
|
65651
|
+
__decorate([
|
|
65652
|
+
Field(() => [KeyValuePairInput], { nullable: true }),
|
|
65653
|
+
__metadata("design:type", Array)
|
|
65654
|
+
], UpdateMJArtifactUseInput.prototype, "OldValues___", void 0);
|
|
65655
|
+
UpdateMJArtifactUseInput = __decorate([
|
|
65656
|
+
InputType()
|
|
65657
|
+
], UpdateMJArtifactUseInput);
|
|
65658
|
+
export { UpdateMJArtifactUseInput };
|
|
65659
|
+
let RunMJArtifactUseViewResult = class RunMJArtifactUseViewResult {
|
|
65660
|
+
Results;
|
|
65661
|
+
UserViewRunID;
|
|
65662
|
+
RowCount;
|
|
65663
|
+
TotalRowCount;
|
|
65664
|
+
ExecutionTime;
|
|
65665
|
+
ErrorMessage;
|
|
65666
|
+
Success;
|
|
65667
|
+
};
|
|
65668
|
+
__decorate([
|
|
65669
|
+
Field(() => [MJArtifactUse_]),
|
|
65670
|
+
__metadata("design:type", Array)
|
|
65671
|
+
], RunMJArtifactUseViewResult.prototype, "Results", void 0);
|
|
65672
|
+
__decorate([
|
|
65673
|
+
Field(() => String, { nullable: true }),
|
|
65674
|
+
__metadata("design:type", String)
|
|
65675
|
+
], RunMJArtifactUseViewResult.prototype, "UserViewRunID", void 0);
|
|
65676
|
+
__decorate([
|
|
65677
|
+
Field(() => Int, { nullable: true }),
|
|
65678
|
+
__metadata("design:type", Number)
|
|
65679
|
+
], RunMJArtifactUseViewResult.prototype, "RowCount", void 0);
|
|
65680
|
+
__decorate([
|
|
65681
|
+
Field(() => Int, { nullable: true }),
|
|
65682
|
+
__metadata("design:type", Number)
|
|
65683
|
+
], RunMJArtifactUseViewResult.prototype, "TotalRowCount", void 0);
|
|
65684
|
+
__decorate([
|
|
65685
|
+
Field(() => Int, { nullable: true }),
|
|
65686
|
+
__metadata("design:type", Number)
|
|
65687
|
+
], RunMJArtifactUseViewResult.prototype, "ExecutionTime", void 0);
|
|
65688
|
+
__decorate([
|
|
65689
|
+
Field({ nullable: true }),
|
|
65690
|
+
__metadata("design:type", String)
|
|
65691
|
+
], RunMJArtifactUseViewResult.prototype, "ErrorMessage", void 0);
|
|
65692
|
+
__decorate([
|
|
65693
|
+
Field(() => Boolean, { nullable: false }),
|
|
65694
|
+
__metadata("design:type", Boolean)
|
|
65695
|
+
], RunMJArtifactUseViewResult.prototype, "Success", void 0);
|
|
65696
|
+
RunMJArtifactUseViewResult = __decorate([
|
|
65697
|
+
ObjectType()
|
|
65698
|
+
], RunMJArtifactUseViewResult);
|
|
65699
|
+
export { RunMJArtifactUseViewResult };
|
|
65700
|
+
let MJArtifactUseResolver = class MJArtifactUseResolver extends ResolverBase {
|
|
65701
|
+
async RunMJArtifactUseViewByID(input, { providers, userPayload }, pubSub) {
|
|
65702
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
65703
|
+
return super.RunViewByIDGeneric(input, provider, userPayload, pubSub);
|
|
65704
|
+
}
|
|
65705
|
+
async RunMJArtifactUseViewByName(input, { providers, userPayload }, pubSub) {
|
|
65706
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
65707
|
+
return super.RunViewByNameGeneric(input, provider, userPayload, pubSub);
|
|
65708
|
+
}
|
|
65709
|
+
async RunMJArtifactUseDynamicView(input, { providers, userPayload }, pubSub) {
|
|
65710
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
65711
|
+
input.EntityName = 'MJ: Artifact Uses';
|
|
65712
|
+
return super.RunDynamicViewGeneric(input, provider, userPayload, pubSub);
|
|
65713
|
+
}
|
|
65714
|
+
async MJArtifactUse(ID, { dataSources, userPayload, providers }, pubSub) {
|
|
65715
|
+
this.CheckUserReadPermissions('MJ: Artifact Uses', userPayload);
|
|
65716
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
65717
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
65718
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwArtifactUses] WHERE [ID]='${ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Artifact Uses', userPayload, EntityPermissionType.Read, 'AND');
|
|
65719
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
65720
|
+
const result = this.MapFieldNamesToCodeNames('MJ: Artifact Uses', rows && rows.length > 0 ? rows[0] : {});
|
|
65721
|
+
return result;
|
|
65722
|
+
}
|
|
65723
|
+
async CreateMJArtifactUse(input, { providers, userPayload }, pubSub) {
|
|
65724
|
+
const provider = GetReadWriteProvider(providers);
|
|
65725
|
+
return this.CreateRecord('MJ: Artifact Uses', input, provider, userPayload, pubSub);
|
|
65726
|
+
}
|
|
65727
|
+
async UpdateMJArtifactUse(input, { providers, userPayload }, pubSub) {
|
|
65728
|
+
const provider = GetReadWriteProvider(providers);
|
|
65729
|
+
return this.UpdateRecord('MJ: Artifact Uses', input, provider, userPayload, pubSub);
|
|
65730
|
+
}
|
|
65731
|
+
async DeleteMJArtifactUse(ID, options, { providers, userPayload }, pubSub) {
|
|
65732
|
+
const provider = GetReadWriteProvider(providers);
|
|
65733
|
+
const key = new CompositeKey([{ FieldName: 'ID', Value: ID }]);
|
|
65734
|
+
return this.DeleteRecord('MJ: Artifact Uses', key, options, provider, userPayload, pubSub);
|
|
65735
|
+
}
|
|
65736
|
+
};
|
|
65737
|
+
__decorate([
|
|
65738
|
+
Query(() => RunMJArtifactUseViewResult),
|
|
65739
|
+
__param(0, Arg('input', () => RunViewByIDInput)),
|
|
65740
|
+
__param(1, Ctx()),
|
|
65741
|
+
__param(2, PubSub()),
|
|
65742
|
+
__metadata("design:type", Function),
|
|
65743
|
+
__metadata("design:paramtypes", [RunViewByIDInput, Object, PubSubEngine]),
|
|
65744
|
+
__metadata("design:returntype", Promise)
|
|
65745
|
+
], MJArtifactUseResolver.prototype, "RunMJArtifactUseViewByID", null);
|
|
65746
|
+
__decorate([
|
|
65747
|
+
Query(() => RunMJArtifactUseViewResult),
|
|
65748
|
+
__param(0, Arg('input', () => RunViewByNameInput)),
|
|
65749
|
+
__param(1, Ctx()),
|
|
65750
|
+
__param(2, PubSub()),
|
|
65751
|
+
__metadata("design:type", Function),
|
|
65752
|
+
__metadata("design:paramtypes", [RunViewByNameInput, Object, PubSubEngine]),
|
|
65753
|
+
__metadata("design:returntype", Promise)
|
|
65754
|
+
], MJArtifactUseResolver.prototype, "RunMJArtifactUseViewByName", null);
|
|
65755
|
+
__decorate([
|
|
65756
|
+
Query(() => RunMJArtifactUseViewResult),
|
|
65757
|
+
__param(0, Arg('input', () => RunDynamicViewInput)),
|
|
65758
|
+
__param(1, Ctx()),
|
|
65759
|
+
__param(2, PubSub()),
|
|
65760
|
+
__metadata("design:type", Function),
|
|
65761
|
+
__metadata("design:paramtypes", [RunDynamicViewInput, Object, PubSubEngine]),
|
|
65762
|
+
__metadata("design:returntype", Promise)
|
|
65763
|
+
], MJArtifactUseResolver.prototype, "RunMJArtifactUseDynamicView", null);
|
|
65764
|
+
__decorate([
|
|
65765
|
+
Query(() => MJArtifactUse_, { nullable: true }),
|
|
65766
|
+
__param(0, Arg('ID', () => String)),
|
|
65767
|
+
__param(1, Ctx()),
|
|
65768
|
+
__param(2, PubSub()),
|
|
65769
|
+
__metadata("design:type", Function),
|
|
65770
|
+
__metadata("design:paramtypes", [String, Object, PubSubEngine]),
|
|
65771
|
+
__metadata("design:returntype", Promise)
|
|
65772
|
+
], MJArtifactUseResolver.prototype, "MJArtifactUse", null);
|
|
65773
|
+
__decorate([
|
|
65774
|
+
Mutation(() => MJArtifactUse_),
|
|
65775
|
+
__param(0, Arg('input', () => CreateMJArtifactUseInput)),
|
|
65776
|
+
__param(1, Ctx()),
|
|
65777
|
+
__param(2, PubSub()),
|
|
65778
|
+
__metadata("design:type", Function),
|
|
65779
|
+
__metadata("design:paramtypes", [CreateMJArtifactUseInput, Object, PubSubEngine]),
|
|
65780
|
+
__metadata("design:returntype", Promise)
|
|
65781
|
+
], MJArtifactUseResolver.prototype, "CreateMJArtifactUse", null);
|
|
65782
|
+
__decorate([
|
|
65783
|
+
Mutation(() => MJArtifactUse_),
|
|
65784
|
+
__param(0, Arg('input', () => UpdateMJArtifactUseInput)),
|
|
65785
|
+
__param(1, Ctx()),
|
|
65786
|
+
__param(2, PubSub()),
|
|
65787
|
+
__metadata("design:type", Function),
|
|
65788
|
+
__metadata("design:paramtypes", [UpdateMJArtifactUseInput, Object, PubSubEngine]),
|
|
65789
|
+
__metadata("design:returntype", Promise)
|
|
65790
|
+
], MJArtifactUseResolver.prototype, "UpdateMJArtifactUse", null);
|
|
65791
|
+
__decorate([
|
|
65792
|
+
Mutation(() => MJArtifactUse_),
|
|
65793
|
+
__param(0, Arg('ID', () => String)),
|
|
65794
|
+
__param(1, Arg('options___', () => DeleteOptionsInput)),
|
|
65795
|
+
__param(2, Ctx()),
|
|
65796
|
+
__param(3, PubSub()),
|
|
65797
|
+
__metadata("design:type", Function),
|
|
65798
|
+
__metadata("design:paramtypes", [String, DeleteOptionsInput, Object, PubSubEngine]),
|
|
65799
|
+
__metadata("design:returntype", Promise)
|
|
65800
|
+
], MJArtifactUseResolver.prototype, "DeleteMJArtifactUse", null);
|
|
65801
|
+
MJArtifactUseResolver = __decorate([
|
|
65802
|
+
Resolver(MJArtifactUse_)
|
|
65803
|
+
], MJArtifactUseResolver);
|
|
65804
|
+
export { MJArtifactUseResolver };
|
|
65335
65805
|
let MJPublicLink_ = class MJPublicLink_ {
|
|
65336
65806
|
ID;
|
|
65337
65807
|
ResourceType;
|
|
@@ -66792,10 +67262,13 @@ let MJAIAgentExample_ = class MJAIAgentExample_ {
|
|
|
66792
67262
|
Status;
|
|
66793
67263
|
_mj__CreatedAt;
|
|
66794
67264
|
_mj__UpdatedAt;
|
|
67265
|
+
EmbeddingVector;
|
|
67266
|
+
EmbeddingModelID;
|
|
66795
67267
|
Agent;
|
|
66796
67268
|
User;
|
|
66797
67269
|
Company;
|
|
66798
67270
|
SourceConversation;
|
|
67271
|
+
EmbeddingModel;
|
|
66799
67272
|
};
|
|
66800
67273
|
__decorate([
|
|
66801
67274
|
Field(),
|
|
@@ -66872,6 +67345,15 @@ __decorate([
|
|
|
66872
67345
|
MaxLength(10),
|
|
66873
67346
|
__metadata("design:type", Date)
|
|
66874
67347
|
], MJAIAgentExample_.prototype, "_mj__UpdatedAt", void 0);
|
|
67348
|
+
__decorate([
|
|
67349
|
+
Field({ nullable: true, description: `JSON array of embedding vector for semantic search on ExampleInput field. Auto-generated when ExampleInput changes.` }),
|
|
67350
|
+
__metadata("design:type", String)
|
|
67351
|
+
], MJAIAgentExample_.prototype, "EmbeddingVector", void 0);
|
|
67352
|
+
__decorate([
|
|
67353
|
+
Field({ nullable: true, description: `Reference to the AI model used to generate the embedding vector.` }),
|
|
67354
|
+
MaxLength(16),
|
|
67355
|
+
__metadata("design:type", String)
|
|
67356
|
+
], MJAIAgentExample_.prototype, "EmbeddingModelID", void 0);
|
|
66875
67357
|
__decorate([
|
|
66876
67358
|
Field({ nullable: true }),
|
|
66877
67359
|
MaxLength(510),
|
|
@@ -66892,6 +67374,11 @@ __decorate([
|
|
|
66892
67374
|
MaxLength(510),
|
|
66893
67375
|
__metadata("design:type", String)
|
|
66894
67376
|
], MJAIAgentExample_.prototype, "SourceConversation", void 0);
|
|
67377
|
+
__decorate([
|
|
67378
|
+
Field({ nullable: true }),
|
|
67379
|
+
MaxLength(100),
|
|
67380
|
+
__metadata("design:type", String)
|
|
67381
|
+
], MJAIAgentExample_.prototype, "EmbeddingModel", void 0);
|
|
66895
67382
|
MJAIAgentExample_ = __decorate([
|
|
66896
67383
|
ObjectType({ description: `Stores example input/output pairs for AI agents to learn from successful interactions. Examples are always agent-specific and support optional user/company scoping for personalized examples.` })
|
|
66897
67384
|
], MJAIAgentExample_);
|
|
@@ -66911,6 +67398,8 @@ let CreateMJAIAgentExampleInput = class CreateMJAIAgentExampleInput {
|
|
|
66911
67398
|
SuccessScore;
|
|
66912
67399
|
Comments;
|
|
66913
67400
|
Status;
|
|
67401
|
+
EmbeddingVector;
|
|
67402
|
+
EmbeddingModelID;
|
|
66914
67403
|
};
|
|
66915
67404
|
__decorate([
|
|
66916
67405
|
Field({ nullable: true }),
|
|
@@ -66968,6 +67457,14 @@ __decorate([
|
|
|
66968
67457
|
Field({ nullable: true }),
|
|
66969
67458
|
__metadata("design:type", String)
|
|
66970
67459
|
], CreateMJAIAgentExampleInput.prototype, "Status", void 0);
|
|
67460
|
+
__decorate([
|
|
67461
|
+
Field({ nullable: true }),
|
|
67462
|
+
__metadata("design:type", String)
|
|
67463
|
+
], CreateMJAIAgentExampleInput.prototype, "EmbeddingVector", void 0);
|
|
67464
|
+
__decorate([
|
|
67465
|
+
Field({ nullable: true }),
|
|
67466
|
+
__metadata("design:type", String)
|
|
67467
|
+
], CreateMJAIAgentExampleInput.prototype, "EmbeddingModelID", void 0);
|
|
66971
67468
|
CreateMJAIAgentExampleInput = __decorate([
|
|
66972
67469
|
InputType()
|
|
66973
67470
|
], CreateMJAIAgentExampleInput);
|
|
@@ -66987,6 +67484,8 @@ let UpdateMJAIAgentExampleInput = class UpdateMJAIAgentExampleInput {
|
|
|
66987
67484
|
SuccessScore;
|
|
66988
67485
|
Comments;
|
|
66989
67486
|
Status;
|
|
67487
|
+
EmbeddingVector;
|
|
67488
|
+
EmbeddingModelID;
|
|
66990
67489
|
OldValues___;
|
|
66991
67490
|
};
|
|
66992
67491
|
__decorate([
|
|
@@ -67045,6 +67544,14 @@ __decorate([
|
|
|
67045
67544
|
Field({ nullable: true }),
|
|
67046
67545
|
__metadata("design:type", String)
|
|
67047
67546
|
], UpdateMJAIAgentExampleInput.prototype, "Status", void 0);
|
|
67547
|
+
__decorate([
|
|
67548
|
+
Field({ nullable: true }),
|
|
67549
|
+
__metadata("design:type", String)
|
|
67550
|
+
], UpdateMJAIAgentExampleInput.prototype, "EmbeddingVector", void 0);
|
|
67551
|
+
__decorate([
|
|
67552
|
+
Field({ nullable: true }),
|
|
67553
|
+
__metadata("design:type", String)
|
|
67554
|
+
], UpdateMJAIAgentExampleInput.prototype, "EmbeddingModelID", void 0);
|
|
67048
67555
|
__decorate([
|
|
67049
67556
|
Field(() => [KeyValuePairInput], { nullable: true }),
|
|
67050
67557
|
__metadata("design:type", Array)
|
|
@@ -67211,8 +67718,8 @@ let MJConversationArtifact_ = class MJConversationArtifact_ {
|
|
|
67211
67718
|
_mj__UpdatedAt;
|
|
67212
67719
|
Conversation;
|
|
67213
67720
|
ArtifactType;
|
|
67214
|
-
MJ_ConversationArtifactPermissions_ConversationArtifactIDArray;
|
|
67215
67721
|
MJ_ConversationArtifactVersions_ConversationArtifactIDArray;
|
|
67722
|
+
MJ_ConversationArtifactPermissions_ConversationArtifactIDArray;
|
|
67216
67723
|
ConversationDetails_ArtifactIDArray;
|
|
67217
67724
|
};
|
|
67218
67725
|
__decorate([
|
|
@@ -67268,14 +67775,14 @@ __decorate([
|
|
|
67268
67775
|
MaxLength(200),
|
|
67269
67776
|
__metadata("design:type", String)
|
|
67270
67777
|
], MJConversationArtifact_.prototype, "ArtifactType", void 0);
|
|
67271
|
-
__decorate([
|
|
67272
|
-
Field(() => [MJConversationArtifactPermission_]),
|
|
67273
|
-
__metadata("design:type", Array)
|
|
67274
|
-
], MJConversationArtifact_.prototype, "MJ_ConversationArtifactPermissions_ConversationArtifactIDArray", void 0);
|
|
67275
67778
|
__decorate([
|
|
67276
67779
|
Field(() => [MJConversationArtifactVersion_]),
|
|
67277
67780
|
__metadata("design:type", Array)
|
|
67278
67781
|
], MJConversationArtifact_.prototype, "MJ_ConversationArtifactVersions_ConversationArtifactIDArray", void 0);
|
|
67782
|
+
__decorate([
|
|
67783
|
+
Field(() => [MJConversationArtifactPermission_]),
|
|
67784
|
+
__metadata("design:type", Array)
|
|
67785
|
+
], MJConversationArtifact_.prototype, "MJ_ConversationArtifactPermissions_ConversationArtifactIDArray", void 0);
|
|
67279
67786
|
__decorate([
|
|
67280
67787
|
Field(() => [MJConversationDetail_]),
|
|
67281
67788
|
__metadata("design:type", Array)
|
|
@@ -67435,22 +67942,22 @@ let MJConversationArtifactResolver = class MJConversationArtifactResolver extend
|
|
|
67435
67942
|
const result = this.MapFieldNamesToCodeNames('MJ: Conversation Artifacts', rows && rows.length > 0 ? rows[0] : {});
|
|
67436
67943
|
return result;
|
|
67437
67944
|
}
|
|
67438
|
-
async
|
|
67439
|
-
this.CheckUserReadPermissions('MJ: Conversation Artifact
|
|
67945
|
+
async MJ_ConversationArtifactVersions_ConversationArtifactIDArray(mjconversationartifact_, { dataSources, userPayload, providers }, pubSub) {
|
|
67946
|
+
this.CheckUserReadPermissions('MJ: Conversation Artifact Versions', userPayload);
|
|
67440
67947
|
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
67441
67948
|
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
67442
|
-
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[
|
|
67949
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwConversationArtifactVersions] WHERE [ConversationArtifactID]='${mjconversationartifact_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Conversation Artifact Versions', userPayload, EntityPermissionType.Read, 'AND');
|
|
67443
67950
|
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
67444
|
-
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Conversation Artifact
|
|
67951
|
+
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Conversation Artifact Versions', rows);
|
|
67445
67952
|
return result;
|
|
67446
67953
|
}
|
|
67447
|
-
async
|
|
67448
|
-
this.CheckUserReadPermissions('MJ: Conversation Artifact
|
|
67954
|
+
async MJ_ConversationArtifactPermissions_ConversationArtifactIDArray(mjconversationartifact_, { dataSources, userPayload, providers }, pubSub) {
|
|
67955
|
+
this.CheckUserReadPermissions('MJ: Conversation Artifact Permissions', userPayload);
|
|
67449
67956
|
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
67450
67957
|
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
67451
|
-
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[
|
|
67958
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwConversationArtifactPermissions] WHERE [ConversationArtifactID]='${mjconversationartifact_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Conversation Artifact Permissions', userPayload, EntityPermissionType.Read, 'AND');
|
|
67452
67959
|
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
67453
|
-
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Conversation Artifact
|
|
67960
|
+
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Conversation Artifact Permissions', rows);
|
|
67454
67961
|
return result;
|
|
67455
67962
|
}
|
|
67456
67963
|
async ConversationDetails_ArtifactIDArray(mjconversationartifact_, { dataSources, userPayload, providers }, pubSub) {
|
|
@@ -67513,23 +68020,23 @@ __decorate([
|
|
|
67513
68020
|
__metadata("design:returntype", Promise)
|
|
67514
68021
|
], MJConversationArtifactResolver.prototype, "MJConversationArtifact", null);
|
|
67515
68022
|
__decorate([
|
|
67516
|
-
FieldResolver(() => [
|
|
68023
|
+
FieldResolver(() => [MJConversationArtifactVersion_]),
|
|
67517
68024
|
__param(0, Root()),
|
|
67518
68025
|
__param(1, Ctx()),
|
|
67519
68026
|
__param(2, PubSub()),
|
|
67520
68027
|
__metadata("design:type", Function),
|
|
67521
68028
|
__metadata("design:paramtypes", [MJConversationArtifact_, Object, PubSubEngine]),
|
|
67522
68029
|
__metadata("design:returntype", Promise)
|
|
67523
|
-
], MJConversationArtifactResolver.prototype, "
|
|
68030
|
+
], MJConversationArtifactResolver.prototype, "MJ_ConversationArtifactVersions_ConversationArtifactIDArray", null);
|
|
67524
68031
|
__decorate([
|
|
67525
|
-
FieldResolver(() => [
|
|
68032
|
+
FieldResolver(() => [MJConversationArtifactPermission_]),
|
|
67526
68033
|
__param(0, Root()),
|
|
67527
68034
|
__param(1, Ctx()),
|
|
67528
68035
|
__param(2, PubSub()),
|
|
67529
68036
|
__metadata("design:type", Function),
|
|
67530
68037
|
__metadata("design:paramtypes", [MJConversationArtifact_, Object, PubSubEngine]),
|
|
67531
68038
|
__metadata("design:returntype", Promise)
|
|
67532
|
-
], MJConversationArtifactResolver.prototype, "
|
|
68039
|
+
], MJConversationArtifactResolver.prototype, "MJ_ConversationArtifactPermissions_ConversationArtifactIDArray", null);
|
|
67533
68040
|
__decorate([
|
|
67534
68041
|
FieldResolver(() => [MJConversationDetail_]),
|
|
67535
68042
|
__param(0, Root()),
|
|
@@ -69608,6 +70115,271 @@ MJQueryParameterResolver = __decorate([
|
|
|
69608
70115
|
Resolver(MJQueryParameter_)
|
|
69609
70116
|
], MJQueryParameterResolver);
|
|
69610
70117
|
export { MJQueryParameterResolver };
|
|
70118
|
+
let MJConversationDetailRating_ = class MJConversationDetailRating_ {
|
|
70119
|
+
ID;
|
|
70120
|
+
ConversationDetailID;
|
|
70121
|
+
UserID;
|
|
70122
|
+
Rating;
|
|
70123
|
+
Comments;
|
|
70124
|
+
_mj__CreatedAt;
|
|
70125
|
+
_mj__UpdatedAt;
|
|
70126
|
+
User;
|
|
70127
|
+
};
|
|
70128
|
+
__decorate([
|
|
70129
|
+
Field(),
|
|
70130
|
+
MaxLength(16),
|
|
70131
|
+
__metadata("design:type", String)
|
|
70132
|
+
], MJConversationDetailRating_.prototype, "ID", void 0);
|
|
70133
|
+
__decorate([
|
|
70134
|
+
Field({ description: `The conversation message being rated.` }),
|
|
70135
|
+
MaxLength(16),
|
|
70136
|
+
__metadata("design:type", String)
|
|
70137
|
+
], MJConversationDetailRating_.prototype, "ConversationDetailID", void 0);
|
|
70138
|
+
__decorate([
|
|
70139
|
+
Field({ description: `The user providing the rating.` }),
|
|
70140
|
+
MaxLength(16),
|
|
70141
|
+
__metadata("design:type", String)
|
|
70142
|
+
], MJConversationDetailRating_.prototype, "UserID", void 0);
|
|
70143
|
+
__decorate([
|
|
70144
|
+
Field(() => Int, { description: `Rating on a 1-10 scale where 1 is thumbs down and 10 is thumbs up.` }),
|
|
70145
|
+
__metadata("design:type", Number)
|
|
70146
|
+
], MJConversationDetailRating_.prototype, "Rating", void 0);
|
|
70147
|
+
__decorate([
|
|
70148
|
+
Field({ nullable: true, description: `Optional textual feedback from the user about this message.` }),
|
|
70149
|
+
__metadata("design:type", String)
|
|
70150
|
+
], MJConversationDetailRating_.prototype, "Comments", void 0);
|
|
70151
|
+
__decorate([
|
|
70152
|
+
Field(),
|
|
70153
|
+
MaxLength(10),
|
|
70154
|
+
__metadata("design:type", Date)
|
|
70155
|
+
], MJConversationDetailRating_.prototype, "_mj__CreatedAt", void 0);
|
|
70156
|
+
__decorate([
|
|
70157
|
+
Field(),
|
|
70158
|
+
MaxLength(10),
|
|
70159
|
+
__metadata("design:type", Date)
|
|
70160
|
+
], MJConversationDetailRating_.prototype, "_mj__UpdatedAt", void 0);
|
|
70161
|
+
__decorate([
|
|
70162
|
+
Field(),
|
|
70163
|
+
MaxLength(200),
|
|
70164
|
+
__metadata("design:type", String)
|
|
70165
|
+
], MJConversationDetailRating_.prototype, "User", void 0);
|
|
70166
|
+
MJConversationDetailRating_ = __decorate([
|
|
70167
|
+
ObjectType({ description: `Stores per-user ratings for conversation messages, supporting multi-user conversations where each user can independently rate messages.` })
|
|
70168
|
+
], MJConversationDetailRating_);
|
|
70169
|
+
export { MJConversationDetailRating_ };
|
|
70170
|
+
let CreateMJConversationDetailRatingInput = class CreateMJConversationDetailRatingInput {
|
|
70171
|
+
ID;
|
|
70172
|
+
ConversationDetailID;
|
|
70173
|
+
UserID;
|
|
70174
|
+
Rating;
|
|
70175
|
+
Comments;
|
|
70176
|
+
};
|
|
70177
|
+
__decorate([
|
|
70178
|
+
Field({ nullable: true }),
|
|
70179
|
+
__metadata("design:type", String)
|
|
70180
|
+
], CreateMJConversationDetailRatingInput.prototype, "ID", void 0);
|
|
70181
|
+
__decorate([
|
|
70182
|
+
Field({ nullable: true }),
|
|
70183
|
+
__metadata("design:type", String)
|
|
70184
|
+
], CreateMJConversationDetailRatingInput.prototype, "ConversationDetailID", void 0);
|
|
70185
|
+
__decorate([
|
|
70186
|
+
Field({ nullable: true }),
|
|
70187
|
+
__metadata("design:type", String)
|
|
70188
|
+
], CreateMJConversationDetailRatingInput.prototype, "UserID", void 0);
|
|
70189
|
+
__decorate([
|
|
70190
|
+
Field(() => Int, { nullable: true }),
|
|
70191
|
+
__metadata("design:type", Number)
|
|
70192
|
+
], CreateMJConversationDetailRatingInput.prototype, "Rating", void 0);
|
|
70193
|
+
__decorate([
|
|
70194
|
+
Field({ nullable: true }),
|
|
70195
|
+
__metadata("design:type", String)
|
|
70196
|
+
], CreateMJConversationDetailRatingInput.prototype, "Comments", void 0);
|
|
70197
|
+
CreateMJConversationDetailRatingInput = __decorate([
|
|
70198
|
+
InputType()
|
|
70199
|
+
], CreateMJConversationDetailRatingInput);
|
|
70200
|
+
export { CreateMJConversationDetailRatingInput };
|
|
70201
|
+
let UpdateMJConversationDetailRatingInput = class UpdateMJConversationDetailRatingInput {
|
|
70202
|
+
ID;
|
|
70203
|
+
ConversationDetailID;
|
|
70204
|
+
UserID;
|
|
70205
|
+
Rating;
|
|
70206
|
+
Comments;
|
|
70207
|
+
OldValues___;
|
|
70208
|
+
};
|
|
70209
|
+
__decorate([
|
|
70210
|
+
Field(),
|
|
70211
|
+
__metadata("design:type", String)
|
|
70212
|
+
], UpdateMJConversationDetailRatingInput.prototype, "ID", void 0);
|
|
70213
|
+
__decorate([
|
|
70214
|
+
Field({ nullable: true }),
|
|
70215
|
+
__metadata("design:type", String)
|
|
70216
|
+
], UpdateMJConversationDetailRatingInput.prototype, "ConversationDetailID", void 0);
|
|
70217
|
+
__decorate([
|
|
70218
|
+
Field({ nullable: true }),
|
|
70219
|
+
__metadata("design:type", String)
|
|
70220
|
+
], UpdateMJConversationDetailRatingInput.prototype, "UserID", void 0);
|
|
70221
|
+
__decorate([
|
|
70222
|
+
Field(() => Int, { nullable: true }),
|
|
70223
|
+
__metadata("design:type", Number)
|
|
70224
|
+
], UpdateMJConversationDetailRatingInput.prototype, "Rating", void 0);
|
|
70225
|
+
__decorate([
|
|
70226
|
+
Field({ nullable: true }),
|
|
70227
|
+
__metadata("design:type", String)
|
|
70228
|
+
], UpdateMJConversationDetailRatingInput.prototype, "Comments", void 0);
|
|
70229
|
+
__decorate([
|
|
70230
|
+
Field(() => [KeyValuePairInput], { nullable: true }),
|
|
70231
|
+
__metadata("design:type", Array)
|
|
70232
|
+
], UpdateMJConversationDetailRatingInput.prototype, "OldValues___", void 0);
|
|
70233
|
+
UpdateMJConversationDetailRatingInput = __decorate([
|
|
70234
|
+
InputType()
|
|
70235
|
+
], UpdateMJConversationDetailRatingInput);
|
|
70236
|
+
export { UpdateMJConversationDetailRatingInput };
|
|
70237
|
+
let RunMJConversationDetailRatingViewResult = class RunMJConversationDetailRatingViewResult {
|
|
70238
|
+
Results;
|
|
70239
|
+
UserViewRunID;
|
|
70240
|
+
RowCount;
|
|
70241
|
+
TotalRowCount;
|
|
70242
|
+
ExecutionTime;
|
|
70243
|
+
ErrorMessage;
|
|
70244
|
+
Success;
|
|
70245
|
+
};
|
|
70246
|
+
__decorate([
|
|
70247
|
+
Field(() => [MJConversationDetailRating_]),
|
|
70248
|
+
__metadata("design:type", Array)
|
|
70249
|
+
], RunMJConversationDetailRatingViewResult.prototype, "Results", void 0);
|
|
70250
|
+
__decorate([
|
|
70251
|
+
Field(() => String, { nullable: true }),
|
|
70252
|
+
__metadata("design:type", String)
|
|
70253
|
+
], RunMJConversationDetailRatingViewResult.prototype, "UserViewRunID", void 0);
|
|
70254
|
+
__decorate([
|
|
70255
|
+
Field(() => Int, { nullable: true }),
|
|
70256
|
+
__metadata("design:type", Number)
|
|
70257
|
+
], RunMJConversationDetailRatingViewResult.prototype, "RowCount", void 0);
|
|
70258
|
+
__decorate([
|
|
70259
|
+
Field(() => Int, { nullable: true }),
|
|
70260
|
+
__metadata("design:type", Number)
|
|
70261
|
+
], RunMJConversationDetailRatingViewResult.prototype, "TotalRowCount", void 0);
|
|
70262
|
+
__decorate([
|
|
70263
|
+
Field(() => Int, { nullable: true }),
|
|
70264
|
+
__metadata("design:type", Number)
|
|
70265
|
+
], RunMJConversationDetailRatingViewResult.prototype, "ExecutionTime", void 0);
|
|
70266
|
+
__decorate([
|
|
70267
|
+
Field({ nullable: true }),
|
|
70268
|
+
__metadata("design:type", String)
|
|
70269
|
+
], RunMJConversationDetailRatingViewResult.prototype, "ErrorMessage", void 0);
|
|
70270
|
+
__decorate([
|
|
70271
|
+
Field(() => Boolean, { nullable: false }),
|
|
70272
|
+
__metadata("design:type", Boolean)
|
|
70273
|
+
], RunMJConversationDetailRatingViewResult.prototype, "Success", void 0);
|
|
70274
|
+
RunMJConversationDetailRatingViewResult = __decorate([
|
|
70275
|
+
ObjectType()
|
|
70276
|
+
], RunMJConversationDetailRatingViewResult);
|
|
70277
|
+
export { RunMJConversationDetailRatingViewResult };
|
|
70278
|
+
let MJConversationDetailRatingResolver = class MJConversationDetailRatingResolver extends ResolverBase {
|
|
70279
|
+
async RunMJConversationDetailRatingViewByID(input, { providers, userPayload }, pubSub) {
|
|
70280
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
70281
|
+
return super.RunViewByIDGeneric(input, provider, userPayload, pubSub);
|
|
70282
|
+
}
|
|
70283
|
+
async RunMJConversationDetailRatingViewByName(input, { providers, userPayload }, pubSub) {
|
|
70284
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
70285
|
+
return super.RunViewByNameGeneric(input, provider, userPayload, pubSub);
|
|
70286
|
+
}
|
|
70287
|
+
async RunMJConversationDetailRatingDynamicView(input, { providers, userPayload }, pubSub) {
|
|
70288
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
70289
|
+
input.EntityName = 'MJ: Conversation Detail Ratings';
|
|
70290
|
+
return super.RunDynamicViewGeneric(input, provider, userPayload, pubSub);
|
|
70291
|
+
}
|
|
70292
|
+
async MJConversationDetailRating(ID, { dataSources, userPayload, providers }, pubSub) {
|
|
70293
|
+
this.CheckUserReadPermissions('MJ: Conversation Detail Ratings', userPayload);
|
|
70294
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
70295
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
70296
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwConversationDetailRatings] WHERE [ID]='${ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Conversation Detail Ratings', userPayload, EntityPermissionType.Read, 'AND');
|
|
70297
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
70298
|
+
const result = this.MapFieldNamesToCodeNames('MJ: Conversation Detail Ratings', rows && rows.length > 0 ? rows[0] : {});
|
|
70299
|
+
return result;
|
|
70300
|
+
}
|
|
70301
|
+
async CreateMJConversationDetailRating(input, { providers, userPayload }, pubSub) {
|
|
70302
|
+
const provider = GetReadWriteProvider(providers);
|
|
70303
|
+
return this.CreateRecord('MJ: Conversation Detail Ratings', input, provider, userPayload, pubSub);
|
|
70304
|
+
}
|
|
70305
|
+
async UpdateMJConversationDetailRating(input, { providers, userPayload }, pubSub) {
|
|
70306
|
+
const provider = GetReadWriteProvider(providers);
|
|
70307
|
+
return this.UpdateRecord('MJ: Conversation Detail Ratings', input, provider, userPayload, pubSub);
|
|
70308
|
+
}
|
|
70309
|
+
async DeleteMJConversationDetailRating(ID, options, { providers, userPayload }, pubSub) {
|
|
70310
|
+
const provider = GetReadWriteProvider(providers);
|
|
70311
|
+
const key = new CompositeKey([{ FieldName: 'ID', Value: ID }]);
|
|
70312
|
+
return this.DeleteRecord('MJ: Conversation Detail Ratings', key, options, provider, userPayload, pubSub);
|
|
70313
|
+
}
|
|
70314
|
+
};
|
|
70315
|
+
__decorate([
|
|
70316
|
+
Query(() => RunMJConversationDetailRatingViewResult),
|
|
70317
|
+
__param(0, Arg('input', () => RunViewByIDInput)),
|
|
70318
|
+
__param(1, Ctx()),
|
|
70319
|
+
__param(2, PubSub()),
|
|
70320
|
+
__metadata("design:type", Function),
|
|
70321
|
+
__metadata("design:paramtypes", [RunViewByIDInput, Object, PubSubEngine]),
|
|
70322
|
+
__metadata("design:returntype", Promise)
|
|
70323
|
+
], MJConversationDetailRatingResolver.prototype, "RunMJConversationDetailRatingViewByID", null);
|
|
70324
|
+
__decorate([
|
|
70325
|
+
Query(() => RunMJConversationDetailRatingViewResult),
|
|
70326
|
+
__param(0, Arg('input', () => RunViewByNameInput)),
|
|
70327
|
+
__param(1, Ctx()),
|
|
70328
|
+
__param(2, PubSub()),
|
|
70329
|
+
__metadata("design:type", Function),
|
|
70330
|
+
__metadata("design:paramtypes", [RunViewByNameInput, Object, PubSubEngine]),
|
|
70331
|
+
__metadata("design:returntype", Promise)
|
|
70332
|
+
], MJConversationDetailRatingResolver.prototype, "RunMJConversationDetailRatingViewByName", null);
|
|
70333
|
+
__decorate([
|
|
70334
|
+
Query(() => RunMJConversationDetailRatingViewResult),
|
|
70335
|
+
__param(0, Arg('input', () => RunDynamicViewInput)),
|
|
70336
|
+
__param(1, Ctx()),
|
|
70337
|
+
__param(2, PubSub()),
|
|
70338
|
+
__metadata("design:type", Function),
|
|
70339
|
+
__metadata("design:paramtypes", [RunDynamicViewInput, Object, PubSubEngine]),
|
|
70340
|
+
__metadata("design:returntype", Promise)
|
|
70341
|
+
], MJConversationDetailRatingResolver.prototype, "RunMJConversationDetailRatingDynamicView", null);
|
|
70342
|
+
__decorate([
|
|
70343
|
+
Query(() => MJConversationDetailRating_, { nullable: true }),
|
|
70344
|
+
__param(0, Arg('ID', () => String)),
|
|
70345
|
+
__param(1, Ctx()),
|
|
70346
|
+
__param(2, PubSub()),
|
|
70347
|
+
__metadata("design:type", Function),
|
|
70348
|
+
__metadata("design:paramtypes", [String, Object, PubSubEngine]),
|
|
70349
|
+
__metadata("design:returntype", Promise)
|
|
70350
|
+
], MJConversationDetailRatingResolver.prototype, "MJConversationDetailRating", null);
|
|
70351
|
+
__decorate([
|
|
70352
|
+
Mutation(() => MJConversationDetailRating_),
|
|
70353
|
+
__param(0, Arg('input', () => CreateMJConversationDetailRatingInput)),
|
|
70354
|
+
__param(1, Ctx()),
|
|
70355
|
+
__param(2, PubSub()),
|
|
70356
|
+
__metadata("design:type", Function),
|
|
70357
|
+
__metadata("design:paramtypes", [CreateMJConversationDetailRatingInput, Object, PubSubEngine]),
|
|
70358
|
+
__metadata("design:returntype", Promise)
|
|
70359
|
+
], MJConversationDetailRatingResolver.prototype, "CreateMJConversationDetailRating", null);
|
|
70360
|
+
__decorate([
|
|
70361
|
+
Mutation(() => MJConversationDetailRating_),
|
|
70362
|
+
__param(0, Arg('input', () => UpdateMJConversationDetailRatingInput)),
|
|
70363
|
+
__param(1, Ctx()),
|
|
70364
|
+
__param(2, PubSub()),
|
|
70365
|
+
__metadata("design:type", Function),
|
|
70366
|
+
__metadata("design:paramtypes", [UpdateMJConversationDetailRatingInput, Object, PubSubEngine]),
|
|
70367
|
+
__metadata("design:returntype", Promise)
|
|
70368
|
+
], MJConversationDetailRatingResolver.prototype, "UpdateMJConversationDetailRating", null);
|
|
70369
|
+
__decorate([
|
|
70370
|
+
Mutation(() => MJConversationDetailRating_),
|
|
70371
|
+
__param(0, Arg('ID', () => String)),
|
|
70372
|
+
__param(1, Arg('options___', () => DeleteOptionsInput)),
|
|
70373
|
+
__param(2, Ctx()),
|
|
70374
|
+
__param(3, PubSub()),
|
|
70375
|
+
__metadata("design:type", Function),
|
|
70376
|
+
__metadata("design:paramtypes", [String, DeleteOptionsInput, Object, PubSubEngine]),
|
|
70377
|
+
__metadata("design:returntype", Promise)
|
|
70378
|
+
], MJConversationDetailRatingResolver.prototype, "DeleteMJConversationDetailRating", null);
|
|
70379
|
+
MJConversationDetailRatingResolver = __decorate([
|
|
70380
|
+
Resolver(MJConversationDetailRating_)
|
|
70381
|
+
], MJConversationDetailRatingResolver);
|
|
70382
|
+
export { MJConversationDetailRatingResolver };
|
|
69611
70383
|
let MJAIAgentPermission_ = class MJAIAgentPermission_ {
|
|
69612
70384
|
ID;
|
|
69613
70385
|
AgentID;
|
|
@@ -69956,6 +70728,8 @@ let MJAIAgentRelationship_ = class MJAIAgentRelationship_ {
|
|
|
69956
70728
|
SubAgentOutputMapping;
|
|
69957
70729
|
SubAgentInputMapping;
|
|
69958
70730
|
SubAgentContextPaths;
|
|
70731
|
+
MessageMode;
|
|
70732
|
+
MaxMessages;
|
|
69959
70733
|
Agent;
|
|
69960
70734
|
SubAgent;
|
|
69961
70735
|
};
|
|
@@ -70001,6 +70775,15 @@ __decorate([
|
|
|
70001
70775
|
Field({ nullable: true, description: `JSON array of parent payload paths to send as LLM context to related sub-agent. Sub-agent receives this data in a formatted context message before its task message. Format: ["path1", "path2.nested", "path3.*", "*"]. Use "*" to send entire parent payload. Example: ["userPreferences", "priorFindings.summary", "sources[*]"]. If null, no parent context is sent (default behavior).` }),
|
|
70002
70776
|
__metadata("design:type", String)
|
|
70003
70777
|
], MJAIAgentRelationship_.prototype, "SubAgentContextPaths", void 0);
|
|
70778
|
+
__decorate([
|
|
70779
|
+
Field({ description: `Specifies how conversation messages are passed from parent agent to related sub-agent. Valid values: 'None' (fresh start - only context and task message, default), 'All' (all parent conversation history), 'Latest' (most recent MaxMessages messages), 'Bookend' (first 2 messages + most recent MaxMessages-2 messages with indicator between). Stored on relationship because related sub-agents can have multiple parents with different message passing needs.` }),
|
|
70780
|
+
MaxLength(100),
|
|
70781
|
+
__metadata("design:type", String)
|
|
70782
|
+
], MJAIAgentRelationship_.prototype, "MessageMode", void 0);
|
|
70783
|
+
__decorate([
|
|
70784
|
+
Field(() => Int, { nullable: true, description: `Maximum number of conversation messages to include when MessageMode is 'Latest' or 'Bookend'. NULL means no limit (ignored for 'None' and 'All' modes). Must be greater than 0 if specified. For 'Latest': keeps most recent N messages. For 'Bookend': keeps first 2 + most recent (N-2) messages.` }),
|
|
70785
|
+
__metadata("design:type", Number)
|
|
70786
|
+
], MJAIAgentRelationship_.prototype, "MaxMessages", void 0);
|
|
70004
70787
|
__decorate([
|
|
70005
70788
|
Field({ nullable: true }),
|
|
70006
70789
|
MaxLength(510),
|
|
@@ -70023,6 +70806,8 @@ let CreateMJAIAgentRelationshipInput = class CreateMJAIAgentRelationshipInput {
|
|
|
70023
70806
|
SubAgentOutputMapping;
|
|
70024
70807
|
SubAgentInputMapping;
|
|
70025
70808
|
SubAgentContextPaths;
|
|
70809
|
+
MessageMode;
|
|
70810
|
+
MaxMessages;
|
|
70026
70811
|
};
|
|
70027
70812
|
__decorate([
|
|
70028
70813
|
Field({ nullable: true }),
|
|
@@ -70052,6 +70837,14 @@ __decorate([
|
|
|
70052
70837
|
Field({ nullable: true }),
|
|
70053
70838
|
__metadata("design:type", String)
|
|
70054
70839
|
], CreateMJAIAgentRelationshipInput.prototype, "SubAgentContextPaths", void 0);
|
|
70840
|
+
__decorate([
|
|
70841
|
+
Field({ nullable: true }),
|
|
70842
|
+
__metadata("design:type", String)
|
|
70843
|
+
], CreateMJAIAgentRelationshipInput.prototype, "MessageMode", void 0);
|
|
70844
|
+
__decorate([
|
|
70845
|
+
Field(() => Int, { nullable: true }),
|
|
70846
|
+
__metadata("design:type", Number)
|
|
70847
|
+
], CreateMJAIAgentRelationshipInput.prototype, "MaxMessages", void 0);
|
|
70055
70848
|
CreateMJAIAgentRelationshipInput = __decorate([
|
|
70056
70849
|
InputType()
|
|
70057
70850
|
], CreateMJAIAgentRelationshipInput);
|
|
@@ -70064,6 +70857,8 @@ let UpdateMJAIAgentRelationshipInput = class UpdateMJAIAgentRelationshipInput {
|
|
|
70064
70857
|
SubAgentOutputMapping;
|
|
70065
70858
|
SubAgentInputMapping;
|
|
70066
70859
|
SubAgentContextPaths;
|
|
70860
|
+
MessageMode;
|
|
70861
|
+
MaxMessages;
|
|
70067
70862
|
OldValues___;
|
|
70068
70863
|
};
|
|
70069
70864
|
__decorate([
|
|
@@ -70094,6 +70889,14 @@ __decorate([
|
|
|
70094
70889
|
Field({ nullable: true }),
|
|
70095
70890
|
__metadata("design:type", String)
|
|
70096
70891
|
], UpdateMJAIAgentRelationshipInput.prototype, "SubAgentContextPaths", void 0);
|
|
70892
|
+
__decorate([
|
|
70893
|
+
Field({ nullable: true }),
|
|
70894
|
+
__metadata("design:type", String)
|
|
70895
|
+
], UpdateMJAIAgentRelationshipInput.prototype, "MessageMode", void 0);
|
|
70896
|
+
__decorate([
|
|
70897
|
+
Field(() => Int, { nullable: true }),
|
|
70898
|
+
__metadata("design:type", Number)
|
|
70899
|
+
], UpdateMJAIAgentRelationshipInput.prototype, "MaxMessages", void 0);
|
|
70097
70900
|
__decorate([
|
|
70098
70901
|
Field(() => [KeyValuePairInput], { nullable: true }),
|
|
70099
70902
|
__metadata("design:type", Array)
|
|
@@ -78483,7 +79286,9 @@ let MJArtifactVersion_ = class MJArtifactVersion_ {
|
|
|
78483
79286
|
Artifact;
|
|
78484
79287
|
User;
|
|
78485
79288
|
MJ_ArtifactVersionAttributes_ArtifactVersionIDArray;
|
|
79289
|
+
MJ_CollectionArtifacts_ArtifactVersionIDArray;
|
|
78486
79290
|
MJ_ConversationDetailArtifacts_ArtifactVersionIDArray;
|
|
79291
|
+
MJ_ArtifactUses_ArtifactVersionIDArray;
|
|
78487
79292
|
};
|
|
78488
79293
|
__decorate([
|
|
78489
79294
|
Field(),
|
|
@@ -78554,10 +79359,18 @@ __decorate([
|
|
|
78554
79359
|
Field(() => [MJArtifactVersionAttribute_]),
|
|
78555
79360
|
__metadata("design:type", Array)
|
|
78556
79361
|
], MJArtifactVersion_.prototype, "MJ_ArtifactVersionAttributes_ArtifactVersionIDArray", void 0);
|
|
79362
|
+
__decorate([
|
|
79363
|
+
Field(() => [MJCollectionArtifact_]),
|
|
79364
|
+
__metadata("design:type", Array)
|
|
79365
|
+
], MJArtifactVersion_.prototype, "MJ_CollectionArtifacts_ArtifactVersionIDArray", void 0);
|
|
78557
79366
|
__decorate([
|
|
78558
79367
|
Field(() => [MJConversationDetailArtifact_]),
|
|
78559
79368
|
__metadata("design:type", Array)
|
|
78560
79369
|
], MJArtifactVersion_.prototype, "MJ_ConversationDetailArtifacts_ArtifactVersionIDArray", void 0);
|
|
79370
|
+
__decorate([
|
|
79371
|
+
Field(() => [MJArtifactUse_]),
|
|
79372
|
+
__metadata("design:type", Array)
|
|
79373
|
+
], MJArtifactVersion_.prototype, "MJ_ArtifactUses_ArtifactVersionIDArray", void 0);
|
|
78561
79374
|
MJArtifactVersion_ = __decorate([
|
|
78562
79375
|
ObjectType({ description: `Version history for artifacts, tracking all changes over time` })
|
|
78563
79376
|
], MJArtifactVersion_);
|
|
@@ -78752,6 +79565,15 @@ let MJArtifactVersionResolver = class MJArtifactVersionResolver extends Resolver
|
|
|
78752
79565
|
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Artifact Version Attributes', rows);
|
|
78753
79566
|
return result;
|
|
78754
79567
|
}
|
|
79568
|
+
async MJ_CollectionArtifacts_ArtifactVersionIDArray(mjartifactversion_, { dataSources, userPayload, providers }, pubSub) {
|
|
79569
|
+
this.CheckUserReadPermissions('MJ: Collection Artifacts', userPayload);
|
|
79570
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
79571
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
79572
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwCollectionArtifacts] WHERE [ArtifactVersionID]='${mjartifactversion_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Collection Artifacts', userPayload, EntityPermissionType.Read, 'AND');
|
|
79573
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
79574
|
+
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Collection Artifacts', rows);
|
|
79575
|
+
return result;
|
|
79576
|
+
}
|
|
78755
79577
|
async MJ_ConversationDetailArtifacts_ArtifactVersionIDArray(mjartifactversion_, { dataSources, userPayload, providers }, pubSub) {
|
|
78756
79578
|
this.CheckUserReadPermissions('MJ: Conversation Detail Artifacts', userPayload);
|
|
78757
79579
|
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
@@ -78761,6 +79583,15 @@ let MJArtifactVersionResolver = class MJArtifactVersionResolver extends Resolver
|
|
|
78761
79583
|
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Conversation Detail Artifacts', rows);
|
|
78762
79584
|
return result;
|
|
78763
79585
|
}
|
|
79586
|
+
async MJ_ArtifactUses_ArtifactVersionIDArray(mjartifactversion_, { dataSources, userPayload, providers }, pubSub) {
|
|
79587
|
+
this.CheckUserReadPermissions('MJ: Artifact Uses', userPayload);
|
|
79588
|
+
const provider = GetReadOnlyProvider(providers, { allowFallbackToReadWrite: true });
|
|
79589
|
+
const connPool = GetReadOnlyDataSource(dataSources, { allowFallbackToReadWrite: true });
|
|
79590
|
+
const sSQL = `SELECT * FROM [${Metadata.Provider.ConfigData.MJCoreSchemaName}].[vwArtifactUses] WHERE [ArtifactVersionID]='${mjartifactversion_.ID}' ` + this.getRowLevelSecurityWhereClause(provider, 'MJ: Artifact Uses', userPayload, EntityPermissionType.Read, 'AND');
|
|
79591
|
+
const rows = await SQLServerDataProvider.ExecuteSQLWithPool(connPool, sSQL, undefined, this.GetUserFromPayload(userPayload));
|
|
79592
|
+
const result = this.ArrayMapFieldNamesToCodeNames('MJ: Artifact Uses', rows);
|
|
79593
|
+
return result;
|
|
79594
|
+
}
|
|
78764
79595
|
async CreateMJArtifactVersion(input, { providers, userPayload }, pubSub) {
|
|
78765
79596
|
const provider = GetReadWriteProvider(providers);
|
|
78766
79597
|
return this.CreateRecord('MJ: Artifact Versions', input, provider, userPayload, pubSub);
|
|
@@ -78820,6 +79651,15 @@ __decorate([
|
|
|
78820
79651
|
__metadata("design:paramtypes", [MJArtifactVersion_, Object, PubSubEngine]),
|
|
78821
79652
|
__metadata("design:returntype", Promise)
|
|
78822
79653
|
], MJArtifactVersionResolver.prototype, "MJ_ArtifactVersionAttributes_ArtifactVersionIDArray", null);
|
|
79654
|
+
__decorate([
|
|
79655
|
+
FieldResolver(() => [MJCollectionArtifact_]),
|
|
79656
|
+
__param(0, Root()),
|
|
79657
|
+
__param(1, Ctx()),
|
|
79658
|
+
__param(2, PubSub()),
|
|
79659
|
+
__metadata("design:type", Function),
|
|
79660
|
+
__metadata("design:paramtypes", [MJArtifactVersion_, Object, PubSubEngine]),
|
|
79661
|
+
__metadata("design:returntype", Promise)
|
|
79662
|
+
], MJArtifactVersionResolver.prototype, "MJ_CollectionArtifacts_ArtifactVersionIDArray", null);
|
|
78823
79663
|
__decorate([
|
|
78824
79664
|
FieldResolver(() => [MJConversationDetailArtifact_]),
|
|
78825
79665
|
__param(0, Root()),
|
|
@@ -78829,6 +79669,15 @@ __decorate([
|
|
|
78829
79669
|
__metadata("design:paramtypes", [MJArtifactVersion_, Object, PubSubEngine]),
|
|
78830
79670
|
__metadata("design:returntype", Promise)
|
|
78831
79671
|
], MJArtifactVersionResolver.prototype, "MJ_ConversationDetailArtifacts_ArtifactVersionIDArray", null);
|
|
79672
|
+
__decorate([
|
|
79673
|
+
FieldResolver(() => [MJArtifactUse_]),
|
|
79674
|
+
__param(0, Root()),
|
|
79675
|
+
__param(1, Ctx()),
|
|
79676
|
+
__param(2, PubSub()),
|
|
79677
|
+
__metadata("design:type", Function),
|
|
79678
|
+
__metadata("design:paramtypes", [MJArtifactVersion_, Object, PubSubEngine]),
|
|
79679
|
+
__metadata("design:returntype", Promise)
|
|
79680
|
+
], MJArtifactVersionResolver.prototype, "MJ_ArtifactUses_ArtifactVersionIDArray", null);
|
|
78832
79681
|
__decorate([
|
|
78833
79682
|
Mutation(() => MJArtifactVersion_),
|
|
78834
79683
|
__param(0, Arg('input', () => CreateMJArtifactVersionInput)),
|