@memberjunction/core-entities 6.1.4 → 6.2.0-edge.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/.tsbuildinfo +1 -1
- package/dist/artifact-extraction/artifact-extractor.d.ts +1 -1
- package/dist/artifact-extraction/artifact-extractor.js +2 -2
- package/dist/custom/MJConversationDetailEntityExtended.d.ts +1 -1
- package/dist/custom/MJConversationDetailEntityExtended.js +5 -5
- package/dist/custom/MJTemplateEntityExtended.d.ts +2 -2
- package/dist/custom/MJTemplateEntityExtended.js +6 -6
- package/dist/custom/MJUserViewEntityExtended.d.ts +4 -4
- package/dist/custom/MJUserViewEntityExtended.js +22 -22
- package/dist/custom/MJUserViewEntityExtended.js.map +1 -1
- package/dist/custom/Permissions/BaseShareEntityExtended.d.ts +8 -0
- package/dist/custom/Permissions/BaseShareEntityExtended.d.ts.map +1 -1
- package/dist/custom/Permissions/BaseShareEntityExtended.js +20 -4
- package/dist/custom/Permissions/BaseShareEntityExtended.js.map +1 -1
- package/dist/custom/Permissions/MJAccessControlRuleEntityExtended.js +4 -4
- package/dist/custom/Permissions/MJArtifactPermissionEntityExtended.js +5 -5
- package/dist/custom/Permissions/MJCollectionPermissionEntityExtended.js +5 -5
- package/dist/custom/Permissions/MJDashboardPermissionEntityExtended.js +5 -5
- package/dist/custom/ResourcePermissions/MJResourcePermissionEntityExtended.js +2 -2
- package/dist/custom/ResourcePermissions/ResourcePermissionEngine.d.ts +2 -2
- package/dist/custom/ResourcePermissions/ResourcePermissionEngine.js +5 -5
- package/dist/engines/ApplicationSettingEngine.d.ts +1 -1
- package/dist/engines/ApplicationSettingEngine.js +8 -8
- package/dist/engines/AuditLogTypeEngine.d.ts +1 -1
- package/dist/engines/AuditLogTypeEngine.js +4 -4
- package/dist/engines/InstanceConfigEngine.d.ts +1 -1
- package/dist/engines/InstanceConfigEngine.js +2 -2
- package/dist/engines/MCPEngine.d.ts +4 -4
- package/dist/engines/MCPEngine.js +24 -24
- package/dist/engines/PermissionEngine.d.ts +2 -0
- package/dist/engines/PermissionEngine.d.ts.map +1 -1
- package/dist/engines/PermissionEngine.js +5 -1
- package/dist/engines/PermissionEngine.js.map +1 -1
- package/dist/engines/ResourceTypeEngine.d.ts +1 -1
- package/dist/engines/ResourceTypeEngine.js +4 -4
- package/dist/engines/TypeTablesCache.d.ts +1 -1
- package/dist/engines/TypeTablesCache.js +3 -3
- package/dist/engines/UserInfoEngine.d.ts +8 -8
- package/dist/engines/UserInfoEngine.js +48 -48
- package/dist/engines/UserRoutineEngine.d.ts +3 -3
- package/dist/engines/UserRoutineEngine.js +15 -15
- package/dist/engines/conversations.d.ts +183 -7
- package/dist/engines/conversations.d.ts.map +1 -1
- package/dist/engines/conversations.js +418 -57
- package/dist/engines/conversations.js.map +1 -1
- package/dist/generated/entities/__mj.d.ts +1999 -292
- package/dist/generated/entities/__mj.d.ts.map +1 -1
- package/dist/generated/entities/__mj.js +1430 -13
- package/dist/generated/entities/__mj.js.map +1 -1
- package/dist/generated/remote_operations.d.ts +100 -0
- package/dist/generated/remote_operations.d.ts.map +1 -1
- package/dist/generated/remote_operations.js +18 -0
- package/dist/generated/remote_operations.js.map +1 -1
- package/package.json +5 -5
|
@@ -2463,8 +2463,8 @@ export const MJAIAgentRunSchema = z.object({
|
|
|
2463
2463
|
TotalCost: z.number().nullable().describe(`
|
|
2464
2464
|
* * Field Name: TotalCost
|
|
2465
2465
|
* * Display Name: Total Cost
|
|
2466
|
-
* * SQL Data Type: decimal(
|
|
2467
|
-
* * Default Value: 0.
|
|
2466
|
+
* * SQL Data Type: decimal(19, 8)
|
|
2467
|
+
* * Default Value: 0.00000000
|
|
2468
2468
|
* * Description: Total estimated cost for all AI model usage during this agent run`),
|
|
2469
2469
|
__mj_CreatedAt: z.date().describe(`
|
|
2470
2470
|
* * Field Name: __mj_CreatedAt
|
|
@@ -6230,7 +6230,7 @@ export const MJAIPromptRunSchema = z.object({
|
|
|
6230
6230
|
TotalCost: z.number().nullable().describe(`
|
|
6231
6231
|
* * Field Name: TotalCost
|
|
6232
6232
|
* * Display Name: Total Cost
|
|
6233
|
-
* * SQL Data Type: decimal(
|
|
6233
|
+
* * SQL Data Type: decimal(19, 8)
|
|
6234
6234
|
* * Description: Total cost of this prompt run including its own cost plus all descendant costs. Calculated as Cost + DescendantCost. This value is stored (not computed) for query performance. Currency is specified in CostCurrency field.`),
|
|
6235
6235
|
Success: z.boolean().describe(`
|
|
6236
6236
|
* * Field Name: Success
|
|
@@ -6359,7 +6359,7 @@ export const MJAIPromptRunSchema = z.object({
|
|
|
6359
6359
|
DescendantCost: z.number().nullable().describe(`
|
|
6360
6360
|
* * Field Name: DescendantCost
|
|
6361
6361
|
* * Display Name: Descendant Cost
|
|
6362
|
-
* * SQL Data Type: decimal(
|
|
6362
|
+
* * SQL Data Type: decimal(19, 8)
|
|
6363
6363
|
* * Description: The total cost of all descendant (child and grandchild) prompt runs, excluding this run's own cost. For leaf nodes (no children), this is 0. Updated when child costs change.`),
|
|
6364
6364
|
ValidationAttemptCount: z.number().nullable().describe(`
|
|
6365
6365
|
* * Field Name: ValidationAttemptCount
|
|
@@ -6656,6 +6656,12 @@ export const MJAIPromptRunSchema = z.object({
|
|
|
6656
6656
|
* * NativeFallback
|
|
6657
6657
|
* * NativeImplicit
|
|
6658
6658
|
* * Description: Which tool-calling path this run actually took. 'Native' = Actions declared as tools, control flow in the JSON envelope (the hybrid). 'NativeImplicit' = Actions, sub-agents, payload_change_request and ask_user declared as tools; a tool call continues the loop and plain text ends the turn. 'Envelope' = no tools declared — the vendor-agnostic JSON-envelope path, including a prompt that asked for native mode on a model/vendor without the capability (also logs a warning). 'NativeFallback' = a native attempt failed in a tools-specific way and completed via a single envelope retry. NULL = pre-feature rows or a run that never reached a model call.`),
|
|
6659
|
+
UserID: z.string().nullable().describe(`
|
|
6660
|
+
* * Field Name: UserID
|
|
6661
|
+
* * Display Name: User ID
|
|
6662
|
+
* * SQL Data Type: uniqueidentifier
|
|
6663
|
+
* * Related Entity/Foreign Key: MJ: Users (vwUsers.ID)
|
|
6664
|
+
* * Description: The user on whose behalf this prompt was executed, written when the run is created. NULL for automated/unauthenticated runs and for runs that pre-date this column. For an agent-driven run the agent run's user is also reachable through AIAgentRunStep.TargetLogID, which vwAIUsageFacts falls back to.`),
|
|
6659
6665
|
Prompt: z.string().describe(`
|
|
6660
6666
|
* * Field Name: Prompt
|
|
6661
6667
|
* * Display Name: Prompt
|
|
@@ -6704,6 +6710,10 @@ export const MJAIPromptRunSchema = z.object({
|
|
|
6704
6710
|
* * Field Name: UsageType
|
|
6705
6711
|
* * Display Name: Usage Type
|
|
6706
6712
|
* * SQL Data Type: nvarchar(50)`),
|
|
6713
|
+
User: z.string().nullable().describe(`
|
|
6714
|
+
* * Field Name: User
|
|
6715
|
+
* * Display Name: User
|
|
6716
|
+
* * SQL Data Type: nvarchar(100)`),
|
|
6707
6717
|
RootParentID: z.string().nullable().describe(`
|
|
6708
6718
|
* * Field Name: RootParentID
|
|
6709
6719
|
* * Display Name: Root Parent
|
|
@@ -7857,6 +7867,12 @@ export const MJAIVendorSchema = z.object({
|
|
|
7857
7867
|
* * SQL Data Type: uniqueidentifier
|
|
7858
7868
|
* * Related Entity/Foreign Key: MJ: Credential Types (vwCredentialTypes.ID)
|
|
7859
7869
|
* * Description: Reference to the type of credential this vendor expects (e.g., API Key, GCP Service Account, Azure Service Principal). Used for type-based default credential resolution when no explicit binding exists, and for UI guidance when creating credentials.`),
|
|
7870
|
+
Configuration: z.any().nullable().describe(`
|
|
7871
|
+
* * Field Name: Configuration
|
|
7872
|
+
* * Display Name: Configuration
|
|
7873
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
7874
|
+
* * JSON Type: MJAIVendorEntity_IAIVendorConfiguration
|
|
7875
|
+
* * Description: Vendor configuration bag (JSON, IAIVendorConfiguration shape). Its ModelDefaults key is an IAIModelConfiguration bag (LLM / Realtime / Vision / Audio sections) that forms the default model configuration for every model this vendor serves: the vendor layer of the ModelConfiguration cascade, above AIModelType and AIModel and below AIModelVendor, which may override it per key. NULL = contributes nothing.`),
|
|
7860
7876
|
CredentialType: z.string().nullable().describe(`
|
|
7861
7877
|
* * Field Name: CredentialType
|
|
7862
7878
|
* * Display Name: Credential Type
|
|
@@ -17844,7 +17860,7 @@ export const MJEntityDocumentSchema = z.object({
|
|
|
17844
17860
|
* * Display Name: Entity
|
|
17845
17861
|
* * SQL Data Type: uniqueidentifier
|
|
17846
17862
|
* * Related Entity/Foreign Key: MJ: Entities (vwEntities.ID)`),
|
|
17847
|
-
VectorDatabaseID: z.string().describe(`
|
|
17863
|
+
VectorDatabaseID: z.string().nullable().describe(`
|
|
17848
17864
|
* * Field Name: VectorDatabaseID
|
|
17849
17865
|
* * Display Name: Vector Database
|
|
17850
17866
|
* * SQL Data Type: uniqueidentifier
|
|
@@ -17863,7 +17879,7 @@ export const MJEntityDocumentSchema = z.object({
|
|
|
17863
17879
|
* * Display Name: Template
|
|
17864
17880
|
* * SQL Data Type: uniqueidentifier
|
|
17865
17881
|
* * Related Entity/Foreign Key: MJ: Templates (vwTemplates.ID)`),
|
|
17866
|
-
AIModelID: z.string().describe(`
|
|
17882
|
+
AIModelID: z.string().nullable().describe(`
|
|
17867
17883
|
* * Field Name: AIModelID
|
|
17868
17884
|
* * Display Name: AI Model
|
|
17869
17885
|
* * SQL Data Type: uniqueidentifier
|
|
@@ -17953,7 +17969,7 @@ export const MJEntityDocumentSchema = z.object({
|
|
|
17953
17969
|
* * Field Name: Entity
|
|
17954
17970
|
* * Display Name: Entity Name
|
|
17955
17971
|
* * SQL Data Type: nvarchar(255)`),
|
|
17956
|
-
VectorDatabase: z.string().describe(`
|
|
17972
|
+
VectorDatabase: z.string().nullable().describe(`
|
|
17957
17973
|
* * Field Name: VectorDatabase
|
|
17958
17974
|
* * Display Name: Vector Database Name
|
|
17959
17975
|
* * SQL Data Type: nvarchar(100)`),
|
|
@@ -17961,7 +17977,7 @@ export const MJEntityDocumentSchema = z.object({
|
|
|
17961
17977
|
* * Field Name: Template
|
|
17962
17978
|
* * Display Name: Template Name
|
|
17963
17979
|
* * SQL Data Type: nvarchar(255)`),
|
|
17964
|
-
AIModel: z.string().describe(`
|
|
17980
|
+
AIModel: z.string().nullable().describe(`
|
|
17965
17981
|
* * Field Name: AIModel
|
|
17966
17982
|
* * Display Name: AI Model Name
|
|
17967
17983
|
* * SQL Data Type: nvarchar(50)`),
|
|
@@ -18541,6 +18557,16 @@ export const MJEntityFieldSchema = z.object({
|
|
|
18541
18557
|
* * SQL Data Type: nvarchar(MAX)
|
|
18542
18558
|
* * JSON Type: MJEntityFieldEntity_IEntityFieldConfiguration
|
|
18543
18559
|
* * Description: Optional JSON configuration bag defining field-level policies and capabilities (shape = IEntityFieldConfiguration). Includes Hierarchy options (IsHierarchy, MaxDepth) to explicitly declare recursive tree hierarchies.`),
|
|
18560
|
+
RelatedEntityFilter: z.string().nullable().describe(`
|
|
18561
|
+
* * Field Name: RelatedEntityFilter
|
|
18562
|
+
* * Display Name: Related Entity Filter
|
|
18563
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
18564
|
+
* * Description: Optional SQL WHERE fragment applied to every lookup on this foreign key (e.g. Status = 'Active'), AND-ed with whatever the user types, on both the browse list and the search path. Lets a picker be scoped from metadata rather than from every form template that renders the field. Authored by hand — CodeGen never derives or overwrites it. NULL means no filter, which is the pre-feature behaviour.`),
|
|
18565
|
+
RelatedEntityOrderBy: z.string().nullable().describe(`
|
|
18566
|
+
* * Field Name: RelatedEntityOrderBy
|
|
18567
|
+
* * Display Name: Related Entity Order By
|
|
18568
|
+
* * SQL Data Type: nvarchar(500)
|
|
18569
|
+
* * Description: Optional ORDER BY fragment for the empty-query browse list on this foreign key, e.g. [Name] or [LastActivityDate] DESC. Does not affect the typed-query path, which is ordered by search relevance. Authored by hand — CodeGen never derives or overwrites it. NULL means order by the related entity's name field.`),
|
|
18544
18570
|
FieldCodeName: z.string().nullable().describe(`
|
|
18545
18571
|
* * Field Name: FieldCodeName
|
|
18546
18572
|
* * Display Name: Field Code Name
|
|
@@ -19943,6 +19969,256 @@ export const MJExternalDataSourceSchema = z.object({
|
|
|
19943
19969
|
* * Display Name: Credential
|
|
19944
19970
|
* * SQL Data Type: nvarchar(200)`),
|
|
19945
19971
|
});
|
|
19972
|
+
/**
|
|
19973
|
+
* zod schema definition for the entity MJ: Feature Value Caches
|
|
19974
|
+
*/
|
|
19975
|
+
export const MJFeatureValueCacheSchema = z.object({
|
|
19976
|
+
ID: z.string().describe(`
|
|
19977
|
+
* * Field Name: ID
|
|
19978
|
+
* * Display Name: ID
|
|
19979
|
+
* * SQL Data Type: uniqueidentifier
|
|
19980
|
+
* * Default Value: newsequentialid()
|
|
19981
|
+
* * Description: Unique identifier for this feature value cache entry.`),
|
|
19982
|
+
RecordProcessID: z.string().nullable().describe(`
|
|
19983
|
+
* * Field Name: RecordProcessID
|
|
19984
|
+
* * Display Name: Record Process
|
|
19985
|
+
* * SQL Data Type: uniqueidentifier
|
|
19986
|
+
* * Related Entity/Foreign Key: MJ: Record Processes (vwRecordProcesses.ID)
|
|
19987
|
+
* * Description: Optional reference to the RecordProcess that produced this cache entry. When NULL, the cached result is scoped by PromptID only and shared across pipelines using the same prompt.`),
|
|
19988
|
+
PromptID: z.string().describe(`
|
|
19989
|
+
* * Field Name: PromptID
|
|
19990
|
+
* * Display Name: Prompt
|
|
19991
|
+
* * SQL Data Type: uniqueidentifier
|
|
19992
|
+
* * Related Entity/Foreign Key: MJ: AI Prompts (vwAIPrompts.ID)
|
|
19993
|
+
* * Description: Reference to the AI Prompt used to compute this cached entry.`),
|
|
19994
|
+
PromptVersionHash: z.string().describe(`
|
|
19995
|
+
* * Field Name: PromptVersionHash
|
|
19996
|
+
* * Display Name: Prompt Version Hash
|
|
19997
|
+
* * SQL Data Type: nvarchar(64)
|
|
19998
|
+
* * Description: SHA-256 content hash of the rendered prompt template, output schema, and constraint instructions at execution time.`),
|
|
19999
|
+
ConstraintHash: z.string().describe(`
|
|
20000
|
+
* * Field Name: ConstraintHash
|
|
20001
|
+
* * Display Name: Constraint Hash
|
|
20002
|
+
* * SQL Data Type: nvarchar(64)
|
|
20003
|
+
* * Description: SHA-256 hash of the output value constraint definitions. Changes to allowed enum values or ranges invalidate cached results.`),
|
|
20004
|
+
KeyHash: z.string().describe(`
|
|
20005
|
+
* * Field Name: KeyHash
|
|
20006
|
+
* * Display Name: Key Hash
|
|
20007
|
+
* * SQL Data Type: nvarchar(64)
|
|
20008
|
+
* * Description: SHA-256 hash over the canonicalized JSON key field values. The primary lookup key.`),
|
|
20009
|
+
KeyDisplay: z.string().nullable().describe(`
|
|
20010
|
+
* * Field Name: KeyDisplay
|
|
20011
|
+
* * Display Name: Key Display
|
|
20012
|
+
* * SQL Data Type: nvarchar(500)
|
|
20013
|
+
* * Description: Human-readable plain text display of the key (e.g. "Senior Director, Field Marketing"). Makes this table legible as reference data.`),
|
|
20014
|
+
KeyJSON: z.string().describe(`
|
|
20015
|
+
* * Field Name: KeyJSON
|
|
20016
|
+
* * Display Name: Key JSON
|
|
20017
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
20018
|
+
* * Description: Full JSON representation of the input key fields and their values.`),
|
|
20019
|
+
OutputsJSON: z.string().describe(`
|
|
20020
|
+
* * Field Name: OutputsJSON
|
|
20021
|
+
* * Display Name: Outputs JSON
|
|
20022
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
20023
|
+
* * Description: Cached computed outputs JSON fragment. Stored directly so archival of AI Prompt Runs does not lose cached values.`),
|
|
20024
|
+
Reasoning: z.string().nullable().describe(`
|
|
20025
|
+
* * Field Name: Reasoning
|
|
20026
|
+
* * Display Name: Reasoning
|
|
20027
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
20028
|
+
* * Description: Optional model reasoning or rationale captured from the prompt execution.`),
|
|
20029
|
+
AIPromptRunID: z.string().nullable().describe(`
|
|
20030
|
+
* * Field Name: AIPromptRunID
|
|
20031
|
+
* * Display Name: AI Prompt Run
|
|
20032
|
+
* * SQL Data Type: uniqueidentifier
|
|
20033
|
+
* * Description: Soft reference to the AI Prompt Run that first computed and populated this cached result.`),
|
|
20034
|
+
HitCount: z.number().describe(`
|
|
20035
|
+
* * Field Name: HitCount
|
|
20036
|
+
* * Display Name: Hit Count
|
|
20037
|
+
* * SQL Data Type: int
|
|
20038
|
+
* * Default Value: 0
|
|
20039
|
+
* * Description: Total number of times this cached result has been served to skip an LLM invocation.`),
|
|
20040
|
+
LastHitAt: z.date().nullable().describe(`
|
|
20041
|
+
* * Field Name: LastHitAt
|
|
20042
|
+
* * Display Name: Last Hit At
|
|
20043
|
+
* * SQL Data Type: datetimeoffset
|
|
20044
|
+
* * Description: Timestamp when this cached entry was last read and served.`),
|
|
20045
|
+
ComputedAt: z.date().describe(`
|
|
20046
|
+
* * Field Name: ComputedAt
|
|
20047
|
+
* * Display Name: Computed At
|
|
20048
|
+
* * SQL Data Type: datetimeoffset
|
|
20049
|
+
* * Default Value: sysdatetimeoffset()
|
|
20050
|
+
* * Description: Timestamp when this cached entry was originally computed.`),
|
|
20051
|
+
ExpiresAt: z.date().nullable().describe(`
|
|
20052
|
+
* * Field Name: ExpiresAt
|
|
20053
|
+
* * Display Name: Expires At
|
|
20054
|
+
* * SQL Data Type: datetimeoffset
|
|
20055
|
+
* * Description: Optional expiration timestamp for time-to-live invalidation. NULL means no expiration.`),
|
|
20056
|
+
__mj_CreatedAt: z.date().describe(`
|
|
20057
|
+
* * Field Name: __mj_CreatedAt
|
|
20058
|
+
* * Display Name: Created At
|
|
20059
|
+
* * SQL Data Type: datetimeoffset
|
|
20060
|
+
* * Default Value: getutcdate()
|
|
20061
|
+
* * Description: Timestamp when this record was created.`),
|
|
20062
|
+
__mj_UpdatedAt: z.date().describe(`
|
|
20063
|
+
* * Field Name: __mj_UpdatedAt
|
|
20064
|
+
* * Display Name: Updated At
|
|
20065
|
+
* * SQL Data Type: datetimeoffset
|
|
20066
|
+
* * Default Value: getutcdate()
|
|
20067
|
+
* * Description: Timestamp when this record was last updated.`),
|
|
20068
|
+
RecordProcess: z.string().nullable().describe(`
|
|
20069
|
+
* * Field Name: RecordProcess
|
|
20070
|
+
* * Display Name: Record Process Name
|
|
20071
|
+
* * SQL Data Type: nvarchar(255)`),
|
|
20072
|
+
Prompt: z.string().describe(`
|
|
20073
|
+
* * Field Name: Prompt
|
|
20074
|
+
* * Display Name: Prompt Name
|
|
20075
|
+
* * SQL Data Type: nvarchar(255)`),
|
|
20076
|
+
});
|
|
20077
|
+
/**
|
|
20078
|
+
* zod schema definition for the entity MJ: Feature Values
|
|
20079
|
+
*/
|
|
20080
|
+
export const MJFeatureValueSchema = z.object({
|
|
20081
|
+
ID: z.string().describe(`
|
|
20082
|
+
* * Field Name: ID
|
|
20083
|
+
* * Display Name: ID
|
|
20084
|
+
* * SQL Data Type: uniqueidentifier
|
|
20085
|
+
* * Default Value: newsequentialid()
|
|
20086
|
+
* * Description: Unique identifier for this feature value history record.`),
|
|
20087
|
+
RecordProcessID: z.string().describe(`
|
|
20088
|
+
* * Field Name: RecordProcessID
|
|
20089
|
+
* * Display Name: Record Process
|
|
20090
|
+
* * SQL Data Type: uniqueidentifier
|
|
20091
|
+
* * Related Entity/Foreign Key: MJ: Record Processes (vwRecordProcesses.ID)
|
|
20092
|
+
* * Description: The Record Process (Feature Pipeline) that computed this feature value.`),
|
|
20093
|
+
EntityID: z.string().describe(`
|
|
20094
|
+
* * Field Name: EntityID
|
|
20095
|
+
* * Display Name: Entity
|
|
20096
|
+
* * SQL Data Type: uniqueidentifier
|
|
20097
|
+
* * Related Entity/Foreign Key: MJ: Entities (vwEntities.ID)
|
|
20098
|
+
* * Description: The entity of the record this feature was computed for.`),
|
|
20099
|
+
RecordID: z.string().describe(`
|
|
20100
|
+
* * Field Name: RecordID
|
|
20101
|
+
* * Display Name: Record ID
|
|
20102
|
+
* * SQL Data Type: nvarchar(900)
|
|
20103
|
+
* * Description: Serialized primary key of the record this feature was computed for. Matches ProcessRunDetail.RecordID.`),
|
|
20104
|
+
FeatureName: z.string().describe(`
|
|
20105
|
+
* * Field Name: FeatureName
|
|
20106
|
+
* * Display Name: Feature Name
|
|
20107
|
+
* * SQL Data Type: nvarchar(255)
|
|
20108
|
+
* * Description: Name of the feature, matching DataFeatureOutput.Name.`),
|
|
20109
|
+
ValueText: z.string().nullable().describe(`
|
|
20110
|
+
* * Field Name: ValueText
|
|
20111
|
+
* * Display Name: Value (Text)
|
|
20112
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
20113
|
+
* * Description: Computed value as text, for text and categorical features.`),
|
|
20114
|
+
ValueNumeric: z.number().nullable().describe(`
|
|
20115
|
+
* * Field Name: ValueNumeric
|
|
20116
|
+
* * Display Name: Value (Numeric)
|
|
20117
|
+
* * SQL Data Type: float(53)
|
|
20118
|
+
* * Description: Computed value as floating-point numeric, for numeric and score features.`),
|
|
20119
|
+
ValueDate: z.date().nullable().describe(`
|
|
20120
|
+
* * Field Name: ValueDate
|
|
20121
|
+
* * Display Name: Value (Date)
|
|
20122
|
+
* * SQL Data Type: datetimeoffset
|
|
20123
|
+
* * Description: Computed value as datetimeoffset, for date and timestamp features.`),
|
|
20124
|
+
ValueBoolean: z.boolean().nullable().describe(`
|
|
20125
|
+
* * Field Name: ValueBoolean
|
|
20126
|
+
* * Display Name: Value (Boolean)
|
|
20127
|
+
* * SQL Data Type: bit
|
|
20128
|
+
* * Description: Computed value as boolean bit flag.`),
|
|
20129
|
+
ValueJSON: z.string().nullable().describe(`
|
|
20130
|
+
* * Field Name: ValueJSON
|
|
20131
|
+
* * Display Name: Value (JSON)
|
|
20132
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
20133
|
+
* * Description: Computed value as raw JSON string, for array or complex object features.`),
|
|
20134
|
+
Reasoning: z.string().nullable().describe(`
|
|
20135
|
+
* * Field Name: Reasoning
|
|
20136
|
+
* * Display Name: Reasoning
|
|
20137
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
20138
|
+
* * Description: Optional model reasoning or rationale captured from the prompt execution.`),
|
|
20139
|
+
Confidence: z.number().nullable().describe(`
|
|
20140
|
+
* * Field Name: Confidence
|
|
20141
|
+
* * Display Name: Confidence
|
|
20142
|
+
* * SQL Data Type: float(53)
|
|
20143
|
+
* * Description: Optional confidence score associated with this computed value.`),
|
|
20144
|
+
PromptID: z.string().nullable().describe(`
|
|
20145
|
+
* * Field Name: PromptID
|
|
20146
|
+
* * Display Name: Prompt
|
|
20147
|
+
* * SQL Data Type: uniqueidentifier
|
|
20148
|
+
* * Related Entity/Foreign Key: MJ: AI Prompts (vwAIPrompts.ID)
|
|
20149
|
+
* * Description: Reference to the AI Prompt used to compute this feature value.`),
|
|
20150
|
+
PromptVersionHash: z.string().nullable().describe(`
|
|
20151
|
+
* * Field Name: PromptVersionHash
|
|
20152
|
+
* * Display Name: Prompt Version Hash
|
|
20153
|
+
* * SQL Data Type: nvarchar(64)
|
|
20154
|
+
* * Description: SHA-256 content hash of the rendered prompt template and instructions at execution time.`),
|
|
20155
|
+
ConstraintHash: z.string().nullable().describe(`
|
|
20156
|
+
* * Field Name: ConstraintHash
|
|
20157
|
+
* * Display Name: Constraint Hash
|
|
20158
|
+
* * SQL Data Type: nvarchar(64)
|
|
20159
|
+
* * Description: SHA-256 hash of the value constraint definitions in effect when this feature was computed.`),
|
|
20160
|
+
ProcessRunID: z.string().nullable().describe(`
|
|
20161
|
+
* * Field Name: ProcessRunID
|
|
20162
|
+
* * Display Name: Process Run
|
|
20163
|
+
* * SQL Data Type: uniqueidentifier
|
|
20164
|
+
* * Related Entity/Foreign Key: MJ: Process Runs (vwProcessRuns.ID)
|
|
20165
|
+
* * Description: Reference to the Process Run during which this feature was computed.`),
|
|
20166
|
+
ProcessRunDetailID: z.string().nullable().describe(`
|
|
20167
|
+
* * Field Name: ProcessRunDetailID
|
|
20168
|
+
* * Display Name: Process Run Detail
|
|
20169
|
+
* * SQL Data Type: uniqueidentifier
|
|
20170
|
+
* * Related Entity/Foreign Key: MJ: Process Run Details (vwProcessRunDetails.ID)
|
|
20171
|
+
* * Description: Reference to the specific Process Run Detail row for this record execution.`),
|
|
20172
|
+
AIPromptRunID: z.string().nullable().describe(`
|
|
20173
|
+
* * Field Name: AIPromptRunID
|
|
20174
|
+
* * Display Name: AI Prompt Run
|
|
20175
|
+
* * SQL Data Type: uniqueidentifier
|
|
20176
|
+
* * Description: Soft reference to the AI Prompt Run that computed this value.`),
|
|
20177
|
+
FeatureValueCacheID: z.string().nullable().describe(`
|
|
20178
|
+
* * Field Name: FeatureValueCacheID
|
|
20179
|
+
* * Display Name: Feature Value Cache
|
|
20180
|
+
* * SQL Data Type: uniqueidentifier
|
|
20181
|
+
* * Related Entity/Foreign Key: MJ: Feature Value Caches (vwFeatureValueCaches.ID)
|
|
20182
|
+
* * Description: Optional reference to the FeatureValueCache entry if this value was served from cache.`),
|
|
20183
|
+
ComputedAt: z.date().describe(`
|
|
20184
|
+
* * Field Name: ComputedAt
|
|
20185
|
+
* * Display Name: Computed At
|
|
20186
|
+
* * SQL Data Type: datetimeoffset
|
|
20187
|
+
* * Default Value: sysdatetimeoffset()
|
|
20188
|
+
* * Description: Timestamp when this feature value was computed.`),
|
|
20189
|
+
__mj_CreatedAt: z.date().describe(`
|
|
20190
|
+
* * Field Name: __mj_CreatedAt
|
|
20191
|
+
* * Display Name: Created At
|
|
20192
|
+
* * SQL Data Type: datetimeoffset
|
|
20193
|
+
* * Default Value: getutcdate()
|
|
20194
|
+
* * Description: Timestamp when this record was created.`),
|
|
20195
|
+
__mj_UpdatedAt: z.date().describe(`
|
|
20196
|
+
* * Field Name: __mj_UpdatedAt
|
|
20197
|
+
* * Display Name: Updated At
|
|
20198
|
+
* * SQL Data Type: datetimeoffset
|
|
20199
|
+
* * Default Value: getutcdate()
|
|
20200
|
+
* * Description: Timestamp when this record was last updated.`),
|
|
20201
|
+
RecordProcess: z.string().describe(`
|
|
20202
|
+
* * Field Name: RecordProcess
|
|
20203
|
+
* * Display Name: Record Process
|
|
20204
|
+
* * SQL Data Type: nvarchar(255)`),
|
|
20205
|
+
Entity: z.string().describe(`
|
|
20206
|
+
* * Field Name: Entity
|
|
20207
|
+
* * Display Name: Entity
|
|
20208
|
+
* * SQL Data Type: nvarchar(255)`),
|
|
20209
|
+
Prompt: z.string().nullable().describe(`
|
|
20210
|
+
* * Field Name: Prompt
|
|
20211
|
+
* * Display Name: Prompt
|
|
20212
|
+
* * SQL Data Type: nvarchar(255)`),
|
|
20213
|
+
ProcessRunDetail: z.string().nullable().describe(`
|
|
20214
|
+
* * Field Name: ProcessRunDetail
|
|
20215
|
+
* * Display Name: Process Run Detail
|
|
20216
|
+
* * SQL Data Type: nvarchar(450)`),
|
|
20217
|
+
FeatureValueCache: z.string().nullable().describe(`
|
|
20218
|
+
* * Field Name: FeatureValueCache
|
|
20219
|
+
* * Display Name: Feature Value Cache
|
|
20220
|
+
* * SQL Data Type: nvarchar(500)`),
|
|
20221
|
+
});
|
|
19946
20222
|
/**
|
|
19947
20223
|
* zod schema definition for the entity MJ: File Categories
|
|
19948
20224
|
*/
|
|
@@ -24802,6 +25078,12 @@ export const MJProjectSchema = z.object({
|
|
|
24802
25078
|
* * Display Name: Updated At
|
|
24803
25079
|
* * SQL Data Type: datetimeoffset
|
|
24804
25080
|
* * Default Value: getutcdate()`),
|
|
25081
|
+
OwnerUserID: z.string().nullable().describe(`
|
|
25082
|
+
* * Field Name: OwnerUserID
|
|
25083
|
+
* * Display Name: Owner User ID
|
|
25084
|
+
* * SQL Data Type: uniqueidentifier
|
|
25085
|
+
* * Related Entity/Foreign Key: MJ: Users (vwUsers.ID)
|
|
25086
|
+
* * Description: The user who owns this folder, or NULL when the folder is shared with the whole environment. NULL (the value every pre-existing folder carries) means SHARED: visible to anyone who can read projects in the environment, which was the only possible behaviour before this column existed. A set value means PERSONAL: the folder belongs to that user and consumers filter it to them, so it stays out of other people's sidebars. Personal is opt-in at create time; nothing is migrated.`),
|
|
24805
25087
|
Environment: z.string().describe(`
|
|
24806
25088
|
* * Field Name: Environment
|
|
24807
25089
|
* * Display Name: Environment
|
|
@@ -24810,6 +25092,10 @@ export const MJProjectSchema = z.object({
|
|
|
24810
25092
|
* * Field Name: Parent
|
|
24811
25093
|
* * Display Name: Parent
|
|
24812
25094
|
* * SQL Data Type: nvarchar(255)`),
|
|
25095
|
+
OwnerUser: z.string().nullable().describe(`
|
|
25096
|
+
* * Field Name: OwnerUser
|
|
25097
|
+
* * Display Name: Owner User
|
|
25098
|
+
* * SQL Data Type: nvarchar(100)`),
|
|
24813
25099
|
RootParentID: z.string().nullable().describe(`
|
|
24814
25100
|
* * Field Name: RootParentID
|
|
24815
25101
|
* * Display Name: Root Parent ID
|
|
@@ -25053,6 +25339,12 @@ export const MJQuerySchema = z.object({
|
|
|
25053
25339
|
* * SQL Data Type: bit
|
|
25054
25340
|
* * Default Value: 0
|
|
25055
25341
|
* * Description: Author's declared intent that this Query should be materialized. CodeGen scans for IsMaterialized = 1 and, if the query qualifies (§9/§10), materializes it. The authoritative state lives on the linked MJ: Materialized Results row (found via the MaterializedResultQuery join table).`),
|
|
25342
|
+
Configuration: z.any().nullable().describe(`
|
|
25343
|
+
* * Field Name: Configuration
|
|
25344
|
+
* * Display Name: Configuration
|
|
25345
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
25346
|
+
* * JSON Type: MJQueryEntity_IQueryConfiguration
|
|
25347
|
+
* * Description: Optional JSON configuration bag defining query-level policies and semantic capabilities (shape = IQueryConfiguration). Includes Priority (1-100) for ground-truth ranking in the semantic layer, LogExecution to control query execution logging, AlternativeQuestions for multi-phrasing vector recall, UsageGuidance and WhenNotToUse bounds for AI agents, and DomainScope.`),
|
|
25056
25348
|
Category: z.string().nullable().describe(`
|
|
25057
25349
|
* * Field Name: Category
|
|
25058
25350
|
* * Display Name: Category Name
|
|
@@ -31421,10 +31713,11 @@ export const MJTestSchema = z.object({
|
|
|
31421
31713
|
* * Display Name: Expected Outcomes
|
|
31422
31714
|
* * SQL Data Type: nvarchar(MAX)
|
|
31423
31715
|
* * Description: JSON object defining what success looks like. Structure varies by test type (e.g., for Agent Eval: {toolCalls, outputFormat, semanticGoals, dataAssertions})`),
|
|
31424
|
-
Configuration: z.
|
|
31716
|
+
Configuration: z.any().nullable().describe(`
|
|
31425
31717
|
* * Field Name: Configuration
|
|
31426
31718
|
* * Display Name: Configuration
|
|
31427
31719
|
* * SQL Data Type: nvarchar(MAX)
|
|
31720
|
+
* * JSON Type: MJTestEntity_ITestConfiguration
|
|
31428
31721
|
* * Description: JSON object for test-specific configuration (e.g., oracles to use, rubrics, retry policies, timeout settings)`),
|
|
31429
31722
|
Tags: z.string().nullable().describe(`
|
|
31430
31723
|
* * Field Name: Tags
|
|
@@ -33402,6 +33695,99 @@ export const MJViewTypeSchema = z.object({
|
|
|
33402
33695
|
* * SQL Data Type: datetimeoffset
|
|
33403
33696
|
* * Default Value: getutcdate()`),
|
|
33404
33697
|
});
|
|
33698
|
+
/**
|
|
33699
|
+
* zod schema definition for the entity MJ: Web Search Providers
|
|
33700
|
+
*/
|
|
33701
|
+
export const MJWebSearchProviderSchema = z.object({
|
|
33702
|
+
ID: z.string().describe(`
|
|
33703
|
+
* * Field Name: ID
|
|
33704
|
+
* * Display Name: ID
|
|
33705
|
+
* * SQL Data Type: uniqueidentifier
|
|
33706
|
+
* * Default Value: newsequentialid()`),
|
|
33707
|
+
Name: z.string().describe(`
|
|
33708
|
+
* * Field Name: Name
|
|
33709
|
+
* * Display Name: Name
|
|
33710
|
+
* * SQL Data Type: nvarchar(200)
|
|
33711
|
+
* * Description: Administrator-facing name for this provider, e.g. "Brave" or "Tavily". Unique, and usable as the Provider value when a caller pins a search to one vendor.`),
|
|
33712
|
+
Description: z.string().nullable().describe(`
|
|
33713
|
+
* * Field Name: Description
|
|
33714
|
+
* * Display Name: Description
|
|
33715
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
33716
|
+
* * Description: What this provider searches, what it costs, and when it is the right choice.`),
|
|
33717
|
+
DriverClass: z.string().describe(`
|
|
33718
|
+
* * Field Name: DriverClass
|
|
33719
|
+
* * Display Name: Driver Class
|
|
33720
|
+
* * SQL Data Type: nvarchar(500)
|
|
33721
|
+
* * Description: ClassFactory key used with @RegisterClass(BaseWebSearchProvider, DriverClass) to instantiate the driver at runtime, e.g. "BraveWebSearchProvider". A value with no matching registration leaves the provider unavailable and is logged at engine startup.`),
|
|
33722
|
+
Status: z.union([z.literal('Active'), z.literal('Pending'), z.literal('Terminated')]).describe(`
|
|
33723
|
+
* * Field Name: Status
|
|
33724
|
+
* * Display Name: Status
|
|
33725
|
+
* * SQL Data Type: nvarchar(20)
|
|
33726
|
+
* * Default Value: Active
|
|
33727
|
+
* * Value List Type: List
|
|
33728
|
+
* * Possible Values
|
|
33729
|
+
* * Active
|
|
33730
|
+
* * Pending
|
|
33731
|
+
* * Terminated
|
|
33732
|
+
* * Description: Provider lifecycle status: Pending (configured but not yet in use), Active (participates in searches), Terminated (disabled). Only Active providers are loaded. Matches the vocabulary used by SearchProvider.`),
|
|
33733
|
+
Priority: z.number().describe(`
|
|
33734
|
+
* * Field Name: Priority
|
|
33735
|
+
* * Display Name: Priority
|
|
33736
|
+
* * SQL Data Type: int
|
|
33737
|
+
* * Default Value: 0
|
|
33738
|
+
* * Description: Failover order: LOWER values are tried FIRST. The engine serves a search from the first available provider in this order, moving on only when one fails transiently. Must be >= 0.`),
|
|
33739
|
+
CredentialID: z.string().nullable().describe(`
|
|
33740
|
+
* * Field Name: CredentialID
|
|
33741
|
+
* * Display Name: Credential ID
|
|
33742
|
+
* * SQL Data Type: uniqueidentifier
|
|
33743
|
+
* * Related Entity/Foreign Key: MJ: Credentials (vwCredentials.ID)
|
|
33744
|
+
* * Description: Optional FK to the Credential record holding this provider's API key. When NULL the driver falls back to its documented environment variable, so a host that has not yet migrated its secrets into the Credential store keeps working.`),
|
|
33745
|
+
ProviderConfig: z.string().nullable().describe(`
|
|
33746
|
+
* * Field Name: ProviderConfig
|
|
33747
|
+
* * Display Name: Provider Config
|
|
33748
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
33749
|
+
* * Description: Optional JSON blob of non-secret, driver-specific settings (endpoint overrides, tier flags, answer model). Schema is defined by each driver; invalid JSON is logged and ignored rather than disabling the provider.`),
|
|
33750
|
+
MaxResultsOverride: z.number().nullable().describe(`
|
|
33751
|
+
* * Field Name: MaxResultsOverride
|
|
33752
|
+
* * Display Name: Max Results Override
|
|
33753
|
+
* * SQL Data Type: int
|
|
33754
|
+
* * Description: Optional per-provider cap on results per request, for pay-per-query vendors. The effective cap is the smallest of the caller's request, this value, and the vendor's own hard limit. NULL means the driver's own limit applies.`),
|
|
33755
|
+
AllowResultCaching: z.boolean().describe(`
|
|
33756
|
+
* * Field Name: AllowResultCaching
|
|
33757
|
+
* * Display Name: Allow Result Caching
|
|
33758
|
+
* * SQL Data Type: bit
|
|
33759
|
+
* * Default Value: 0
|
|
33760
|
+
* * Description: Whether this vendor's terms permit storing returned results. Defaults to 0 (deny), because caching rights differ sharply between vendors and violating them is silent: some sell storage rights as a plan tier, others forbid persistent caching outright. Nothing in the engine caches today; this column exists so the first caching layer reads a per-provider gate instead of inventing one.`),
|
|
33761
|
+
DisplayName: z.string().nullable().describe(`
|
|
33762
|
+
* * Field Name: DisplayName
|
|
33763
|
+
* * Display Name: Display Name
|
|
33764
|
+
* * SQL Data Type: nvarchar(200)
|
|
33765
|
+
* * Description: UI display name shown in admin surfaces and result attribution. When NULL, falls back to the Name column.`),
|
|
33766
|
+
Icon: z.string().nullable().describe(`
|
|
33767
|
+
* * Field Name: Icon
|
|
33768
|
+
* * Display Name: Icon
|
|
33769
|
+
* * SQL Data Type: nvarchar(200)
|
|
33770
|
+
* * Description: CSS icon class for UI display, e.g. "fa-brands fa-brave". Supports any CSS-based icon library. When NULL a default icon is used.`),
|
|
33771
|
+
Comments: z.string().nullable().describe(`
|
|
33772
|
+
* * Field Name: Comments
|
|
33773
|
+
* * Display Name: Comments
|
|
33774
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
33775
|
+
* * Description: Free-form administrator notes, e.g. contract terms, billing owner, or why this provider sits at its priority.`),
|
|
33776
|
+
__mj_CreatedAt: z.date().describe(`
|
|
33777
|
+
* * Field Name: __mj_CreatedAt
|
|
33778
|
+
* * Display Name: Created At
|
|
33779
|
+
* * SQL Data Type: datetimeoffset
|
|
33780
|
+
* * Default Value: getutcdate()`),
|
|
33781
|
+
__mj_UpdatedAt: z.date().describe(`
|
|
33782
|
+
* * Field Name: __mj_UpdatedAt
|
|
33783
|
+
* * Display Name: Updated At
|
|
33784
|
+
* * SQL Data Type: datetimeoffset
|
|
33785
|
+
* * Default Value: getutcdate()`),
|
|
33786
|
+
Credential: z.string().nullable().describe(`
|
|
33787
|
+
* * Field Name: Credential
|
|
33788
|
+
* * Display Name: Credential
|
|
33789
|
+
* * SQL Data Type: nvarchar(200)`),
|
|
33790
|
+
});
|
|
33405
33791
|
/**
|
|
33406
33792
|
* zod schema definition for the entity MJ: Workspace Items
|
|
33407
33793
|
*/
|
|
@@ -39051,6 +39437,7 @@ let MJAIAgentRunStepEntity = class MJAIAgentRunStepEntity extends BaseEntity {
|
|
|
39051
39437
|
/**
|
|
39052
39438
|
* Validate() method override for MJ: AI Agent Run Steps entity. This is an auto-generated method that invokes the generated validators for this entity for the following fields:
|
|
39053
39439
|
* * FinalPayloadValidationResult: The final payload validation result must be one of the approved statuses: Warn, Fail, Retry, or Pass, to ensure consistent reporting of validation outcomes.
|
|
39440
|
+
* * NativeToolCallCount: The native tool call count must be greater than or equal to zero, if it is specified.
|
|
39054
39441
|
* * StepNumber: This rule ensures that the step number must be greater than zero.
|
|
39055
39442
|
* @public
|
|
39056
39443
|
* @method
|
|
@@ -39059,6 +39446,7 @@ let MJAIAgentRunStepEntity = class MJAIAgentRunStepEntity extends BaseEntity {
|
|
|
39059
39446
|
Validate() {
|
|
39060
39447
|
const result = super.Validate();
|
|
39061
39448
|
this.ValidateFinalPayloadValidationResultStatus(result);
|
|
39449
|
+
this.ValidateNativeToolCallCountGreaterThanOrEqualToZero(result);
|
|
39062
39450
|
this.ValidateStepNumberGreaterThanZero(result);
|
|
39063
39451
|
result.Success = result.Success && (result.Errors.length === 0);
|
|
39064
39452
|
return result;
|
|
@@ -39078,6 +39466,17 @@ let MJAIAgentRunStepEntity = class MJAIAgentRunStepEntity extends BaseEntity {
|
|
|
39078
39466
|
}
|
|
39079
39467
|
}
|
|
39080
39468
|
/**
|
|
39469
|
+
* The native tool call count must be greater than or equal to zero, if it is specified.
|
|
39470
|
+
* @param result - the ValidationResult object to add any errors or warnings to
|
|
39471
|
+
* @public
|
|
39472
|
+
* @method
|
|
39473
|
+
*/
|
|
39474
|
+
ValidateNativeToolCallCountGreaterThanOrEqualToZero(result) {
|
|
39475
|
+
if (this.NativeToolCallCount != null && this.NativeToolCallCount < 0) {
|
|
39476
|
+
result.Errors.push(new ValidationErrorInfo("NativeToolCallCount", "The native tool call count must be 0 or greater.", this.NativeToolCallCount, ValidationErrorType.Failure));
|
|
39477
|
+
}
|
|
39478
|
+
}
|
|
39479
|
+
/**
|
|
39081
39480
|
* This rule ensures that the step number must be greater than zero.
|
|
39082
39481
|
* @param result - the ValidationResult object to add any errors or warnings to
|
|
39083
39482
|
* @public
|
|
@@ -39831,8 +40230,8 @@ let MJAIAgentRunEntity = class MJAIAgentRunEntity extends BaseEntity {
|
|
|
39831
40230
|
/**
|
|
39832
40231
|
* * Field Name: TotalCost
|
|
39833
40232
|
* * Display Name: Total Cost
|
|
39834
|
-
* * SQL Data Type: decimal(
|
|
39835
|
-
* * Default Value: 0.
|
|
40233
|
+
* * SQL Data Type: decimal(19, 8)
|
|
40234
|
+
* * Default Value: 0.00000000
|
|
39836
40235
|
* * Description: Total estimated cost for all AI model usage during this agent run
|
|
39837
40236
|
*/
|
|
39838
40237
|
get TotalCost() {
|
|
@@ -49818,7 +50217,7 @@ let MJAIPromptRunEntity = class MJAIPromptRunEntity extends BaseEntity {
|
|
|
49818
50217
|
/**
|
|
49819
50218
|
* * Field Name: TotalCost
|
|
49820
50219
|
* * Display Name: Total Cost
|
|
49821
|
-
* * SQL Data Type: decimal(
|
|
50220
|
+
* * SQL Data Type: decimal(19, 8)
|
|
49822
50221
|
* * Description: Total cost of this prompt run including its own cost plus all descendant costs. Calculated as Cost + DescendantCost. This value is stored (not computed) for query performance. Currency is specified in CostCurrency field.
|
|
49823
50222
|
*/
|
|
49824
50223
|
get TotalCost() {
|
|
@@ -50109,7 +50508,7 @@ let MJAIPromptRunEntity = class MJAIPromptRunEntity extends BaseEntity {
|
|
|
50109
50508
|
/**
|
|
50110
50509
|
* * Field Name: DescendantCost
|
|
50111
50510
|
* * Display Name: Descendant Cost
|
|
50112
|
-
* * SQL Data Type: decimal(
|
|
50511
|
+
* * SQL Data Type: decimal(19, 8)
|
|
50113
50512
|
* * Description: The total cost of all descendant (child and grandchild) prompt runs, excluding this run's own cost. For leaf nodes (no children), this is 0. Updated when child costs change.
|
|
50114
50513
|
*/
|
|
50115
50514
|
get DescendantCost() {
|
|
@@ -50785,6 +51184,19 @@ let MJAIPromptRunEntity = class MJAIPromptRunEntity extends BaseEntity {
|
|
|
50785
51184
|
this.Set('ToolCallingMode', value);
|
|
50786
51185
|
}
|
|
50787
51186
|
/**
|
|
51187
|
+
* * Field Name: UserID
|
|
51188
|
+
* * Display Name: User ID
|
|
51189
|
+
* * SQL Data Type: uniqueidentifier
|
|
51190
|
+
* * Related Entity/Foreign Key: MJ: Users (vwUsers.ID)
|
|
51191
|
+
* * Description: The user on whose behalf this prompt was executed, written when the run is created. NULL for automated/unauthenticated runs and for runs that pre-date this column. For an agent-driven run the agent run's user is also reachable through AIAgentRunStep.TargetLogID, which vwAIUsageFacts falls back to.
|
|
51192
|
+
*/
|
|
51193
|
+
get UserID() {
|
|
51194
|
+
return this.Get('UserID');
|
|
51195
|
+
}
|
|
51196
|
+
set UserID(value) {
|
|
51197
|
+
this.Set('UserID', value);
|
|
51198
|
+
}
|
|
51199
|
+
/**
|
|
50788
51200
|
* * Field Name: Prompt
|
|
50789
51201
|
* * Display Name: Prompt
|
|
50790
51202
|
* * SQL Data Type: nvarchar(255)
|
|
@@ -50881,6 +51293,14 @@ let MJAIPromptRunEntity = class MJAIPromptRunEntity extends BaseEntity {
|
|
|
50881
51293
|
return this.Get('UsageType');
|
|
50882
51294
|
}
|
|
50883
51295
|
/**
|
|
51296
|
+
* * Field Name: User
|
|
51297
|
+
* * Display Name: User
|
|
51298
|
+
* * SQL Data Type: nvarchar(100)
|
|
51299
|
+
*/
|
|
51300
|
+
get User() {
|
|
51301
|
+
return this.Get('User');
|
|
51302
|
+
}
|
|
51303
|
+
/**
|
|
50884
51304
|
* * Field Name: RootParentID
|
|
50885
51305
|
* * Display Name: Root Parent
|
|
50886
51306
|
* * SQL Data Type: uniqueidentifier
|
|
@@ -53680,6 +54100,11 @@ export { MJAIVendorTypeEntity };
|
|
|
53680
54100
|
* @public
|
|
53681
54101
|
*/
|
|
53682
54102
|
let MJAIVendorEntity = class MJAIVendorEntity extends BaseEntity {
|
|
54103
|
+
constructor() {
|
|
54104
|
+
super(...arguments);
|
|
54105
|
+
this._ConfigurationObject_cached = undefined;
|
|
54106
|
+
this._ConfigurationObject_lastRaw = null;
|
|
54107
|
+
}
|
|
53683
54108
|
/**
|
|
53684
54109
|
* Loads the MJ: AI Vendors record from the database
|
|
53685
54110
|
* @param ID: string - primary key value to load the MJ: AI Vendors record.
|
|
@@ -53764,6 +54189,37 @@ let MJAIVendorEntity = class MJAIVendorEntity extends BaseEntity {
|
|
|
53764
54189
|
this.Set('CredentialTypeID', value);
|
|
53765
54190
|
}
|
|
53766
54191
|
/**
|
|
54192
|
+
* * Field Name: Configuration
|
|
54193
|
+
* * Display Name: Configuration
|
|
54194
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
54195
|
+
* * JSON Type: MJAIVendorEntity_IAIVendorConfiguration
|
|
54196
|
+
* * Description: Vendor configuration bag (JSON, IAIVendorConfiguration shape). Its ModelDefaults key is an IAIModelConfiguration bag (LLM / Realtime / Vision / Audio sections) that forms the default model configuration for every model this vendor serves: the vendor layer of the ModelConfiguration cascade, above AIModelType and AIModel and below AIModelVendor, which may override it per key. NULL = contributes nothing.
|
|
54197
|
+
*/
|
|
54198
|
+
get Configuration() {
|
|
54199
|
+
return this.Get('Configuration');
|
|
54200
|
+
}
|
|
54201
|
+
set Configuration(value) {
|
|
54202
|
+
this.Set('Configuration', value);
|
|
54203
|
+
}
|
|
54204
|
+
/**
|
|
54205
|
+
* Typed accessor for Configuration — returns parsed JSON as MJAIVendorEntity_IAIVendorConfiguration.
|
|
54206
|
+
* Uses lazy parsing with cache invalidation when the underlying raw value changes.
|
|
54207
|
+
*/
|
|
54208
|
+
get ConfigurationObject() {
|
|
54209
|
+
const raw = this.Configuration;
|
|
54210
|
+
if (raw !== this._ConfigurationObject_lastRaw) {
|
|
54211
|
+
this._ConfigurationObject_cached = raw ? JSON.parse(raw) : null;
|
|
54212
|
+
this._ConfigurationObject_lastRaw = raw;
|
|
54213
|
+
}
|
|
54214
|
+
return this._ConfigurationObject_cached;
|
|
54215
|
+
}
|
|
54216
|
+
set ConfigurationObject(value) {
|
|
54217
|
+
const raw = value ? JSON.stringify(value) : null;
|
|
54218
|
+
this.Configuration = raw;
|
|
54219
|
+
this._ConfigurationObject_cached = value;
|
|
54220
|
+
this._ConfigurationObject_lastRaw = raw;
|
|
54221
|
+
}
|
|
54222
|
+
/**
|
|
53767
54223
|
* * Field Name: CredentialType
|
|
53768
54224
|
* * Display Name: Credential Type
|
|
53769
54225
|
* * SQL Data Type: nvarchar(100)
|
|
@@ -80343,6 +80799,30 @@ let MJEntityFieldEntity = class MJEntityFieldEntity extends BaseEntity {
|
|
|
80343
80799
|
this._ConfigurationObject_lastRaw = raw;
|
|
80344
80800
|
}
|
|
80345
80801
|
/**
|
|
80802
|
+
* * Field Name: RelatedEntityFilter
|
|
80803
|
+
* * Display Name: Related Entity Filter
|
|
80804
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
80805
|
+
* * Description: Optional SQL WHERE fragment applied to every lookup on this foreign key (e.g. Status = 'Active'), AND-ed with whatever the user types, on both the browse list and the search path. Lets a picker be scoped from metadata rather than from every form template that renders the field. Authored by hand — CodeGen never derives or overwrites it. NULL means no filter, which is the pre-feature behaviour.
|
|
80806
|
+
*/
|
|
80807
|
+
get RelatedEntityFilter() {
|
|
80808
|
+
return this.Get('RelatedEntityFilter');
|
|
80809
|
+
}
|
|
80810
|
+
set RelatedEntityFilter(value) {
|
|
80811
|
+
this.Set('RelatedEntityFilter', value);
|
|
80812
|
+
}
|
|
80813
|
+
/**
|
|
80814
|
+
* * Field Name: RelatedEntityOrderBy
|
|
80815
|
+
* * Display Name: Related Entity Order By
|
|
80816
|
+
* * SQL Data Type: nvarchar(500)
|
|
80817
|
+
* * Description: Optional ORDER BY fragment for the empty-query browse list on this foreign key, e.g. [Name] or [LastActivityDate] DESC. Does not affect the typed-query path, which is ordered by search relevance. Authored by hand — CodeGen never derives or overwrites it. NULL means order by the related entity's name field.
|
|
80818
|
+
*/
|
|
80819
|
+
get RelatedEntityOrderBy() {
|
|
80820
|
+
return this.Get('RelatedEntityOrderBy');
|
|
80821
|
+
}
|
|
80822
|
+
set RelatedEntityOrderBy(value) {
|
|
80823
|
+
this.Set('RelatedEntityOrderBy', value);
|
|
80824
|
+
}
|
|
80825
|
+
/**
|
|
80346
80826
|
* * Field Name: FieldCodeName
|
|
80347
80827
|
* * Display Name: Field Code Name
|
|
80348
80828
|
* * SQL Data Type: nvarchar(MAX)
|
|
@@ -83804,6 +84284,601 @@ MJExternalDataSourceEntity = __decorate([
|
|
|
83804
84284
|
RegisterClass(BaseEntity, 'MJ: External Data Sources')
|
|
83805
84285
|
], MJExternalDataSourceEntity);
|
|
83806
84286
|
export { MJExternalDataSourceEntity };
|
|
84287
|
+
/**
|
|
84288
|
+
* MJ: Feature Value Caches - strongly typed entity sub-class
|
|
84289
|
+
* * Schema: __mj
|
|
84290
|
+
* * Base Table: FeatureValueCache
|
|
84291
|
+
* * Base View: vwFeatureValueCaches
|
|
84292
|
+
* * @description Dedup dictionary table for Feature Pipelines. Caches computed outputs by canonical input key hash, prompt version, and constraint hash. Distinct input strings (e.g. unique job titles) are computed once and reused across all matching records.
|
|
84293
|
+
* * Primary Key: ID
|
|
84294
|
+
* @extends {BaseEntity}
|
|
84295
|
+
* @class
|
|
84296
|
+
* @public
|
|
84297
|
+
*/
|
|
84298
|
+
let MJFeatureValueCacheEntity = class MJFeatureValueCacheEntity extends BaseEntity {
|
|
84299
|
+
/**
|
|
84300
|
+
* Loads the MJ: Feature Value Caches record from the database
|
|
84301
|
+
* @param ID: string - primary key value to load the MJ: Feature Value Caches record.
|
|
84302
|
+
* @param EntityRelationshipsToLoad - (optional) the relationships to load
|
|
84303
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
84304
|
+
* @public
|
|
84305
|
+
* @async
|
|
84306
|
+
* @memberof MJFeatureValueCacheEntity
|
|
84307
|
+
* @method
|
|
84308
|
+
* @override
|
|
84309
|
+
*/
|
|
84310
|
+
async Load(ID, EntityRelationshipsToLoad) {
|
|
84311
|
+
const compositeKey = new CompositeKey();
|
|
84312
|
+
compositeKey.KeyValuePairs.push({ FieldName: 'ID', Value: ID });
|
|
84313
|
+
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
84314
|
+
}
|
|
84315
|
+
/**
|
|
84316
|
+
* * Field Name: ID
|
|
84317
|
+
* * Display Name: ID
|
|
84318
|
+
* * SQL Data Type: uniqueidentifier
|
|
84319
|
+
* * Default Value: newsequentialid()
|
|
84320
|
+
* * Description: Unique identifier for this feature value cache entry.
|
|
84321
|
+
*/
|
|
84322
|
+
get ID() {
|
|
84323
|
+
return this.Get('ID');
|
|
84324
|
+
}
|
|
84325
|
+
set ID(value) {
|
|
84326
|
+
this.Set('ID', value);
|
|
84327
|
+
}
|
|
84328
|
+
/**
|
|
84329
|
+
* * Field Name: RecordProcessID
|
|
84330
|
+
* * Display Name: Record Process
|
|
84331
|
+
* * SQL Data Type: uniqueidentifier
|
|
84332
|
+
* * Related Entity/Foreign Key: MJ: Record Processes (vwRecordProcesses.ID)
|
|
84333
|
+
* * Description: Optional reference to the RecordProcess that produced this cache entry. When NULL, the cached result is scoped by PromptID only and shared across pipelines using the same prompt.
|
|
84334
|
+
*/
|
|
84335
|
+
get RecordProcessID() {
|
|
84336
|
+
return this.Get('RecordProcessID');
|
|
84337
|
+
}
|
|
84338
|
+
set RecordProcessID(value) {
|
|
84339
|
+
this.Set('RecordProcessID', value);
|
|
84340
|
+
}
|
|
84341
|
+
/**
|
|
84342
|
+
* * Field Name: PromptID
|
|
84343
|
+
* * Display Name: Prompt
|
|
84344
|
+
* * SQL Data Type: uniqueidentifier
|
|
84345
|
+
* * Related Entity/Foreign Key: MJ: AI Prompts (vwAIPrompts.ID)
|
|
84346
|
+
* * Description: Reference to the AI Prompt used to compute this cached entry.
|
|
84347
|
+
*/
|
|
84348
|
+
get PromptID() {
|
|
84349
|
+
return this.Get('PromptID');
|
|
84350
|
+
}
|
|
84351
|
+
set PromptID(value) {
|
|
84352
|
+
this.Set('PromptID', value);
|
|
84353
|
+
}
|
|
84354
|
+
/**
|
|
84355
|
+
* * Field Name: PromptVersionHash
|
|
84356
|
+
* * Display Name: Prompt Version Hash
|
|
84357
|
+
* * SQL Data Type: nvarchar(64)
|
|
84358
|
+
* * Description: SHA-256 content hash of the rendered prompt template, output schema, and constraint instructions at execution time.
|
|
84359
|
+
*/
|
|
84360
|
+
get PromptVersionHash() {
|
|
84361
|
+
return this.Get('PromptVersionHash');
|
|
84362
|
+
}
|
|
84363
|
+
set PromptVersionHash(value) {
|
|
84364
|
+
this.Set('PromptVersionHash', value);
|
|
84365
|
+
}
|
|
84366
|
+
/**
|
|
84367
|
+
* * Field Name: ConstraintHash
|
|
84368
|
+
* * Display Name: Constraint Hash
|
|
84369
|
+
* * SQL Data Type: nvarchar(64)
|
|
84370
|
+
* * Description: SHA-256 hash of the output value constraint definitions. Changes to allowed enum values or ranges invalidate cached results.
|
|
84371
|
+
*/
|
|
84372
|
+
get ConstraintHash() {
|
|
84373
|
+
return this.Get('ConstraintHash');
|
|
84374
|
+
}
|
|
84375
|
+
set ConstraintHash(value) {
|
|
84376
|
+
this.Set('ConstraintHash', value);
|
|
84377
|
+
}
|
|
84378
|
+
/**
|
|
84379
|
+
* * Field Name: KeyHash
|
|
84380
|
+
* * Display Name: Key Hash
|
|
84381
|
+
* * SQL Data Type: nvarchar(64)
|
|
84382
|
+
* * Description: SHA-256 hash over the canonicalized JSON key field values. The primary lookup key.
|
|
84383
|
+
*/
|
|
84384
|
+
get KeyHash() {
|
|
84385
|
+
return this.Get('KeyHash');
|
|
84386
|
+
}
|
|
84387
|
+
set KeyHash(value) {
|
|
84388
|
+
this.Set('KeyHash', value);
|
|
84389
|
+
}
|
|
84390
|
+
/**
|
|
84391
|
+
* * Field Name: KeyDisplay
|
|
84392
|
+
* * Display Name: Key Display
|
|
84393
|
+
* * SQL Data Type: nvarchar(500)
|
|
84394
|
+
* * Description: Human-readable plain text display of the key (e.g. "Senior Director, Field Marketing"). Makes this table legible as reference data.
|
|
84395
|
+
*/
|
|
84396
|
+
get KeyDisplay() {
|
|
84397
|
+
return this.Get('KeyDisplay');
|
|
84398
|
+
}
|
|
84399
|
+
set KeyDisplay(value) {
|
|
84400
|
+
this.Set('KeyDisplay', value);
|
|
84401
|
+
}
|
|
84402
|
+
/**
|
|
84403
|
+
* * Field Name: KeyJSON
|
|
84404
|
+
* * Display Name: Key JSON
|
|
84405
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
84406
|
+
* * Description: Full JSON representation of the input key fields and their values.
|
|
84407
|
+
*/
|
|
84408
|
+
get KeyJSON() {
|
|
84409
|
+
return this.Get('KeyJSON');
|
|
84410
|
+
}
|
|
84411
|
+
set KeyJSON(value) {
|
|
84412
|
+
this.Set('KeyJSON', value);
|
|
84413
|
+
}
|
|
84414
|
+
/**
|
|
84415
|
+
* * Field Name: OutputsJSON
|
|
84416
|
+
* * Display Name: Outputs JSON
|
|
84417
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
84418
|
+
* * Description: Cached computed outputs JSON fragment. Stored directly so archival of AI Prompt Runs does not lose cached values.
|
|
84419
|
+
*/
|
|
84420
|
+
get OutputsJSON() {
|
|
84421
|
+
return this.Get('OutputsJSON');
|
|
84422
|
+
}
|
|
84423
|
+
set OutputsJSON(value) {
|
|
84424
|
+
this.Set('OutputsJSON', value);
|
|
84425
|
+
}
|
|
84426
|
+
/**
|
|
84427
|
+
* * Field Name: Reasoning
|
|
84428
|
+
* * Display Name: Reasoning
|
|
84429
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
84430
|
+
* * Description: Optional model reasoning or rationale captured from the prompt execution.
|
|
84431
|
+
*/
|
|
84432
|
+
get Reasoning() {
|
|
84433
|
+
return this.Get('Reasoning');
|
|
84434
|
+
}
|
|
84435
|
+
set Reasoning(value) {
|
|
84436
|
+
this.Set('Reasoning', value);
|
|
84437
|
+
}
|
|
84438
|
+
/**
|
|
84439
|
+
* * Field Name: AIPromptRunID
|
|
84440
|
+
* * Display Name: AI Prompt Run
|
|
84441
|
+
* * SQL Data Type: uniqueidentifier
|
|
84442
|
+
* * Description: Soft reference to the AI Prompt Run that first computed and populated this cached result.
|
|
84443
|
+
*/
|
|
84444
|
+
get AIPromptRunID() {
|
|
84445
|
+
return this.Get('AIPromptRunID');
|
|
84446
|
+
}
|
|
84447
|
+
set AIPromptRunID(value) {
|
|
84448
|
+
this.Set('AIPromptRunID', value);
|
|
84449
|
+
}
|
|
84450
|
+
/**
|
|
84451
|
+
* * Field Name: HitCount
|
|
84452
|
+
* * Display Name: Hit Count
|
|
84453
|
+
* * SQL Data Type: int
|
|
84454
|
+
* * Default Value: 0
|
|
84455
|
+
* * Description: Total number of times this cached result has been served to skip an LLM invocation.
|
|
84456
|
+
*/
|
|
84457
|
+
get HitCount() {
|
|
84458
|
+
return this.Get('HitCount');
|
|
84459
|
+
}
|
|
84460
|
+
set HitCount(value) {
|
|
84461
|
+
this.Set('HitCount', value);
|
|
84462
|
+
}
|
|
84463
|
+
/**
|
|
84464
|
+
* * Field Name: LastHitAt
|
|
84465
|
+
* * Display Name: Last Hit At
|
|
84466
|
+
* * SQL Data Type: datetimeoffset
|
|
84467
|
+
* * Description: Timestamp when this cached entry was last read and served.
|
|
84468
|
+
*/
|
|
84469
|
+
get LastHitAt() {
|
|
84470
|
+
return this.Get('LastHitAt');
|
|
84471
|
+
}
|
|
84472
|
+
set LastHitAt(value) {
|
|
84473
|
+
this.Set('LastHitAt', value);
|
|
84474
|
+
}
|
|
84475
|
+
/**
|
|
84476
|
+
* * Field Name: ComputedAt
|
|
84477
|
+
* * Display Name: Computed At
|
|
84478
|
+
* * SQL Data Type: datetimeoffset
|
|
84479
|
+
* * Default Value: sysdatetimeoffset()
|
|
84480
|
+
* * Description: Timestamp when this cached entry was originally computed.
|
|
84481
|
+
*/
|
|
84482
|
+
get ComputedAt() {
|
|
84483
|
+
return this.Get('ComputedAt');
|
|
84484
|
+
}
|
|
84485
|
+
set ComputedAt(value) {
|
|
84486
|
+
this.Set('ComputedAt', value);
|
|
84487
|
+
}
|
|
84488
|
+
/**
|
|
84489
|
+
* * Field Name: ExpiresAt
|
|
84490
|
+
* * Display Name: Expires At
|
|
84491
|
+
* * SQL Data Type: datetimeoffset
|
|
84492
|
+
* * Description: Optional expiration timestamp for time-to-live invalidation. NULL means no expiration.
|
|
84493
|
+
*/
|
|
84494
|
+
get ExpiresAt() {
|
|
84495
|
+
return this.Get('ExpiresAt');
|
|
84496
|
+
}
|
|
84497
|
+
set ExpiresAt(value) {
|
|
84498
|
+
this.Set('ExpiresAt', value);
|
|
84499
|
+
}
|
|
84500
|
+
/**
|
|
84501
|
+
* * Field Name: __mj_CreatedAt
|
|
84502
|
+
* * Display Name: Created At
|
|
84503
|
+
* * SQL Data Type: datetimeoffset
|
|
84504
|
+
* * Default Value: getutcdate()
|
|
84505
|
+
* * Description: Timestamp when this record was created.
|
|
84506
|
+
*/
|
|
84507
|
+
get __mj_CreatedAt() {
|
|
84508
|
+
return this.Get('__mj_CreatedAt');
|
|
84509
|
+
}
|
|
84510
|
+
/**
|
|
84511
|
+
* * Field Name: __mj_UpdatedAt
|
|
84512
|
+
* * Display Name: Updated At
|
|
84513
|
+
* * SQL Data Type: datetimeoffset
|
|
84514
|
+
* * Default Value: getutcdate()
|
|
84515
|
+
* * Description: Timestamp when this record was last updated.
|
|
84516
|
+
*/
|
|
84517
|
+
get __mj_UpdatedAt() {
|
|
84518
|
+
return this.Get('__mj_UpdatedAt');
|
|
84519
|
+
}
|
|
84520
|
+
/**
|
|
84521
|
+
* * Field Name: RecordProcess
|
|
84522
|
+
* * Display Name: Record Process Name
|
|
84523
|
+
* * SQL Data Type: nvarchar(255)
|
|
84524
|
+
*/
|
|
84525
|
+
get RecordProcess() {
|
|
84526
|
+
return this.Get('RecordProcess');
|
|
84527
|
+
}
|
|
84528
|
+
/**
|
|
84529
|
+
* * Field Name: Prompt
|
|
84530
|
+
* * Display Name: Prompt Name
|
|
84531
|
+
* * SQL Data Type: nvarchar(255)
|
|
84532
|
+
*/
|
|
84533
|
+
get Prompt() {
|
|
84534
|
+
return this.Get('Prompt');
|
|
84535
|
+
}
|
|
84536
|
+
};
|
|
84537
|
+
MJFeatureValueCacheEntity = __decorate([
|
|
84538
|
+
RegisterClass(BaseEntity, 'MJ: Feature Value Caches')
|
|
84539
|
+
], MJFeatureValueCacheEntity);
|
|
84540
|
+
export { MJFeatureValueCacheEntity };
|
|
84541
|
+
/**
|
|
84542
|
+
* MJ: Feature Values - strongly typed entity sub-class
|
|
84543
|
+
* * Schema: __mj
|
|
84544
|
+
* * Base Table: FeatureValue
|
|
84545
|
+
* * Base View: vwFeatureValues
|
|
84546
|
+
* * @description Complete historical audit table for Feature Pipelines. Records every feature value ever computed per entity record, with full provenance, model reasoning, and run back-links.
|
|
84547
|
+
* * Primary Key: ID
|
|
84548
|
+
* @extends {BaseEntity}
|
|
84549
|
+
* @class
|
|
84550
|
+
* @public
|
|
84551
|
+
*/
|
|
84552
|
+
let MJFeatureValueEntity = class MJFeatureValueEntity extends BaseEntity {
|
|
84553
|
+
/**
|
|
84554
|
+
* Loads the MJ: Feature Values record from the database
|
|
84555
|
+
* @param ID: string - primary key value to load the MJ: Feature Values record.
|
|
84556
|
+
* @param EntityRelationshipsToLoad - (optional) the relationships to load
|
|
84557
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
84558
|
+
* @public
|
|
84559
|
+
* @async
|
|
84560
|
+
* @memberof MJFeatureValueEntity
|
|
84561
|
+
* @method
|
|
84562
|
+
* @override
|
|
84563
|
+
*/
|
|
84564
|
+
async Load(ID, EntityRelationshipsToLoad) {
|
|
84565
|
+
const compositeKey = new CompositeKey();
|
|
84566
|
+
compositeKey.KeyValuePairs.push({ FieldName: 'ID', Value: ID });
|
|
84567
|
+
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
84568
|
+
}
|
|
84569
|
+
/**
|
|
84570
|
+
* * Field Name: ID
|
|
84571
|
+
* * Display Name: ID
|
|
84572
|
+
* * SQL Data Type: uniqueidentifier
|
|
84573
|
+
* * Default Value: newsequentialid()
|
|
84574
|
+
* * Description: Unique identifier for this feature value history record.
|
|
84575
|
+
*/
|
|
84576
|
+
get ID() {
|
|
84577
|
+
return this.Get('ID');
|
|
84578
|
+
}
|
|
84579
|
+
set ID(value) {
|
|
84580
|
+
this.Set('ID', value);
|
|
84581
|
+
}
|
|
84582
|
+
/**
|
|
84583
|
+
* * Field Name: RecordProcessID
|
|
84584
|
+
* * Display Name: Record Process
|
|
84585
|
+
* * SQL Data Type: uniqueidentifier
|
|
84586
|
+
* * Related Entity/Foreign Key: MJ: Record Processes (vwRecordProcesses.ID)
|
|
84587
|
+
* * Description: The Record Process (Feature Pipeline) that computed this feature value.
|
|
84588
|
+
*/
|
|
84589
|
+
get RecordProcessID() {
|
|
84590
|
+
return this.Get('RecordProcessID');
|
|
84591
|
+
}
|
|
84592
|
+
set RecordProcessID(value) {
|
|
84593
|
+
this.Set('RecordProcessID', value);
|
|
84594
|
+
}
|
|
84595
|
+
/**
|
|
84596
|
+
* * Field Name: EntityID
|
|
84597
|
+
* * Display Name: Entity
|
|
84598
|
+
* * SQL Data Type: uniqueidentifier
|
|
84599
|
+
* * Related Entity/Foreign Key: MJ: Entities (vwEntities.ID)
|
|
84600
|
+
* * Description: The entity of the record this feature was computed for.
|
|
84601
|
+
*/
|
|
84602
|
+
get EntityID() {
|
|
84603
|
+
return this.Get('EntityID');
|
|
84604
|
+
}
|
|
84605
|
+
set EntityID(value) {
|
|
84606
|
+
this.Set('EntityID', value);
|
|
84607
|
+
}
|
|
84608
|
+
/**
|
|
84609
|
+
* * Field Name: RecordID
|
|
84610
|
+
* * Display Name: Record ID
|
|
84611
|
+
* * SQL Data Type: nvarchar(900)
|
|
84612
|
+
* * Description: Serialized primary key of the record this feature was computed for. Matches ProcessRunDetail.RecordID.
|
|
84613
|
+
*/
|
|
84614
|
+
get RecordID() {
|
|
84615
|
+
return this.Get('RecordID');
|
|
84616
|
+
}
|
|
84617
|
+
set RecordID(value) {
|
|
84618
|
+
this.Set('RecordID', value);
|
|
84619
|
+
}
|
|
84620
|
+
/**
|
|
84621
|
+
* * Field Name: FeatureName
|
|
84622
|
+
* * Display Name: Feature Name
|
|
84623
|
+
* * SQL Data Type: nvarchar(255)
|
|
84624
|
+
* * Description: Name of the feature, matching DataFeatureOutput.Name.
|
|
84625
|
+
*/
|
|
84626
|
+
get FeatureName() {
|
|
84627
|
+
return this.Get('FeatureName');
|
|
84628
|
+
}
|
|
84629
|
+
set FeatureName(value) {
|
|
84630
|
+
this.Set('FeatureName', value);
|
|
84631
|
+
}
|
|
84632
|
+
/**
|
|
84633
|
+
* * Field Name: ValueText
|
|
84634
|
+
* * Display Name: Value (Text)
|
|
84635
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
84636
|
+
* * Description: Computed value as text, for text and categorical features.
|
|
84637
|
+
*/
|
|
84638
|
+
get ValueText() {
|
|
84639
|
+
return this.Get('ValueText');
|
|
84640
|
+
}
|
|
84641
|
+
set ValueText(value) {
|
|
84642
|
+
this.Set('ValueText', value);
|
|
84643
|
+
}
|
|
84644
|
+
/**
|
|
84645
|
+
* * Field Name: ValueNumeric
|
|
84646
|
+
* * Display Name: Value (Numeric)
|
|
84647
|
+
* * SQL Data Type: float(53)
|
|
84648
|
+
* * Description: Computed value as floating-point numeric, for numeric and score features.
|
|
84649
|
+
*/
|
|
84650
|
+
get ValueNumeric() {
|
|
84651
|
+
return this.Get('ValueNumeric');
|
|
84652
|
+
}
|
|
84653
|
+
set ValueNumeric(value) {
|
|
84654
|
+
this.Set('ValueNumeric', value);
|
|
84655
|
+
}
|
|
84656
|
+
/**
|
|
84657
|
+
* * Field Name: ValueDate
|
|
84658
|
+
* * Display Name: Value (Date)
|
|
84659
|
+
* * SQL Data Type: datetimeoffset
|
|
84660
|
+
* * Description: Computed value as datetimeoffset, for date and timestamp features.
|
|
84661
|
+
*/
|
|
84662
|
+
get ValueDate() {
|
|
84663
|
+
return this.Get('ValueDate');
|
|
84664
|
+
}
|
|
84665
|
+
set ValueDate(value) {
|
|
84666
|
+
this.Set('ValueDate', value);
|
|
84667
|
+
}
|
|
84668
|
+
/**
|
|
84669
|
+
* * Field Name: ValueBoolean
|
|
84670
|
+
* * Display Name: Value (Boolean)
|
|
84671
|
+
* * SQL Data Type: bit
|
|
84672
|
+
* * Description: Computed value as boolean bit flag.
|
|
84673
|
+
*/
|
|
84674
|
+
get ValueBoolean() {
|
|
84675
|
+
return this.Get('ValueBoolean');
|
|
84676
|
+
}
|
|
84677
|
+
set ValueBoolean(value) {
|
|
84678
|
+
this.Set('ValueBoolean', value);
|
|
84679
|
+
}
|
|
84680
|
+
/**
|
|
84681
|
+
* * Field Name: ValueJSON
|
|
84682
|
+
* * Display Name: Value (JSON)
|
|
84683
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
84684
|
+
* * Description: Computed value as raw JSON string, for array or complex object features.
|
|
84685
|
+
*/
|
|
84686
|
+
get ValueJSON() {
|
|
84687
|
+
return this.Get('ValueJSON');
|
|
84688
|
+
}
|
|
84689
|
+
set ValueJSON(value) {
|
|
84690
|
+
this.Set('ValueJSON', value);
|
|
84691
|
+
}
|
|
84692
|
+
/**
|
|
84693
|
+
* * Field Name: Reasoning
|
|
84694
|
+
* * Display Name: Reasoning
|
|
84695
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
84696
|
+
* * Description: Optional model reasoning or rationale captured from the prompt execution.
|
|
84697
|
+
*/
|
|
84698
|
+
get Reasoning() {
|
|
84699
|
+
return this.Get('Reasoning');
|
|
84700
|
+
}
|
|
84701
|
+
set Reasoning(value) {
|
|
84702
|
+
this.Set('Reasoning', value);
|
|
84703
|
+
}
|
|
84704
|
+
/**
|
|
84705
|
+
* * Field Name: Confidence
|
|
84706
|
+
* * Display Name: Confidence
|
|
84707
|
+
* * SQL Data Type: float(53)
|
|
84708
|
+
* * Description: Optional confidence score associated with this computed value.
|
|
84709
|
+
*/
|
|
84710
|
+
get Confidence() {
|
|
84711
|
+
return this.Get('Confidence');
|
|
84712
|
+
}
|
|
84713
|
+
set Confidence(value) {
|
|
84714
|
+
this.Set('Confidence', value);
|
|
84715
|
+
}
|
|
84716
|
+
/**
|
|
84717
|
+
* * Field Name: PromptID
|
|
84718
|
+
* * Display Name: Prompt
|
|
84719
|
+
* * SQL Data Type: uniqueidentifier
|
|
84720
|
+
* * Related Entity/Foreign Key: MJ: AI Prompts (vwAIPrompts.ID)
|
|
84721
|
+
* * Description: Reference to the AI Prompt used to compute this feature value.
|
|
84722
|
+
*/
|
|
84723
|
+
get PromptID() {
|
|
84724
|
+
return this.Get('PromptID');
|
|
84725
|
+
}
|
|
84726
|
+
set PromptID(value) {
|
|
84727
|
+
this.Set('PromptID', value);
|
|
84728
|
+
}
|
|
84729
|
+
/**
|
|
84730
|
+
* * Field Name: PromptVersionHash
|
|
84731
|
+
* * Display Name: Prompt Version Hash
|
|
84732
|
+
* * SQL Data Type: nvarchar(64)
|
|
84733
|
+
* * Description: SHA-256 content hash of the rendered prompt template and instructions at execution time.
|
|
84734
|
+
*/
|
|
84735
|
+
get PromptVersionHash() {
|
|
84736
|
+
return this.Get('PromptVersionHash');
|
|
84737
|
+
}
|
|
84738
|
+
set PromptVersionHash(value) {
|
|
84739
|
+
this.Set('PromptVersionHash', value);
|
|
84740
|
+
}
|
|
84741
|
+
/**
|
|
84742
|
+
* * Field Name: ConstraintHash
|
|
84743
|
+
* * Display Name: Constraint Hash
|
|
84744
|
+
* * SQL Data Type: nvarchar(64)
|
|
84745
|
+
* * Description: SHA-256 hash of the value constraint definitions in effect when this feature was computed.
|
|
84746
|
+
*/
|
|
84747
|
+
get ConstraintHash() {
|
|
84748
|
+
return this.Get('ConstraintHash');
|
|
84749
|
+
}
|
|
84750
|
+
set ConstraintHash(value) {
|
|
84751
|
+
this.Set('ConstraintHash', value);
|
|
84752
|
+
}
|
|
84753
|
+
/**
|
|
84754
|
+
* * Field Name: ProcessRunID
|
|
84755
|
+
* * Display Name: Process Run
|
|
84756
|
+
* * SQL Data Type: uniqueidentifier
|
|
84757
|
+
* * Related Entity/Foreign Key: MJ: Process Runs (vwProcessRuns.ID)
|
|
84758
|
+
* * Description: Reference to the Process Run during which this feature was computed.
|
|
84759
|
+
*/
|
|
84760
|
+
get ProcessRunID() {
|
|
84761
|
+
return this.Get('ProcessRunID');
|
|
84762
|
+
}
|
|
84763
|
+
set ProcessRunID(value) {
|
|
84764
|
+
this.Set('ProcessRunID', value);
|
|
84765
|
+
}
|
|
84766
|
+
/**
|
|
84767
|
+
* * Field Name: ProcessRunDetailID
|
|
84768
|
+
* * Display Name: Process Run Detail
|
|
84769
|
+
* * SQL Data Type: uniqueidentifier
|
|
84770
|
+
* * Related Entity/Foreign Key: MJ: Process Run Details (vwProcessRunDetails.ID)
|
|
84771
|
+
* * Description: Reference to the specific Process Run Detail row for this record execution.
|
|
84772
|
+
*/
|
|
84773
|
+
get ProcessRunDetailID() {
|
|
84774
|
+
return this.Get('ProcessRunDetailID');
|
|
84775
|
+
}
|
|
84776
|
+
set ProcessRunDetailID(value) {
|
|
84777
|
+
this.Set('ProcessRunDetailID', value);
|
|
84778
|
+
}
|
|
84779
|
+
/**
|
|
84780
|
+
* * Field Name: AIPromptRunID
|
|
84781
|
+
* * Display Name: AI Prompt Run
|
|
84782
|
+
* * SQL Data Type: uniqueidentifier
|
|
84783
|
+
* * Description: Soft reference to the AI Prompt Run that computed this value.
|
|
84784
|
+
*/
|
|
84785
|
+
get AIPromptRunID() {
|
|
84786
|
+
return this.Get('AIPromptRunID');
|
|
84787
|
+
}
|
|
84788
|
+
set AIPromptRunID(value) {
|
|
84789
|
+
this.Set('AIPromptRunID', value);
|
|
84790
|
+
}
|
|
84791
|
+
/**
|
|
84792
|
+
* * Field Name: FeatureValueCacheID
|
|
84793
|
+
* * Display Name: Feature Value Cache
|
|
84794
|
+
* * SQL Data Type: uniqueidentifier
|
|
84795
|
+
* * Related Entity/Foreign Key: MJ: Feature Value Caches (vwFeatureValueCaches.ID)
|
|
84796
|
+
* * Description: Optional reference to the FeatureValueCache entry if this value was served from cache.
|
|
84797
|
+
*/
|
|
84798
|
+
get FeatureValueCacheID() {
|
|
84799
|
+
return this.Get('FeatureValueCacheID');
|
|
84800
|
+
}
|
|
84801
|
+
set FeatureValueCacheID(value) {
|
|
84802
|
+
this.Set('FeatureValueCacheID', value);
|
|
84803
|
+
}
|
|
84804
|
+
/**
|
|
84805
|
+
* * Field Name: ComputedAt
|
|
84806
|
+
* * Display Name: Computed At
|
|
84807
|
+
* * SQL Data Type: datetimeoffset
|
|
84808
|
+
* * Default Value: sysdatetimeoffset()
|
|
84809
|
+
* * Description: Timestamp when this feature value was computed.
|
|
84810
|
+
*/
|
|
84811
|
+
get ComputedAt() {
|
|
84812
|
+
return this.Get('ComputedAt');
|
|
84813
|
+
}
|
|
84814
|
+
set ComputedAt(value) {
|
|
84815
|
+
this.Set('ComputedAt', value);
|
|
84816
|
+
}
|
|
84817
|
+
/**
|
|
84818
|
+
* * Field Name: __mj_CreatedAt
|
|
84819
|
+
* * Display Name: Created At
|
|
84820
|
+
* * SQL Data Type: datetimeoffset
|
|
84821
|
+
* * Default Value: getutcdate()
|
|
84822
|
+
* * Description: Timestamp when this record was created.
|
|
84823
|
+
*/
|
|
84824
|
+
get __mj_CreatedAt() {
|
|
84825
|
+
return this.Get('__mj_CreatedAt');
|
|
84826
|
+
}
|
|
84827
|
+
/**
|
|
84828
|
+
* * Field Name: __mj_UpdatedAt
|
|
84829
|
+
* * Display Name: Updated At
|
|
84830
|
+
* * SQL Data Type: datetimeoffset
|
|
84831
|
+
* * Default Value: getutcdate()
|
|
84832
|
+
* * Description: Timestamp when this record was last updated.
|
|
84833
|
+
*/
|
|
84834
|
+
get __mj_UpdatedAt() {
|
|
84835
|
+
return this.Get('__mj_UpdatedAt');
|
|
84836
|
+
}
|
|
84837
|
+
/**
|
|
84838
|
+
* * Field Name: RecordProcess
|
|
84839
|
+
* * Display Name: Record Process
|
|
84840
|
+
* * SQL Data Type: nvarchar(255)
|
|
84841
|
+
*/
|
|
84842
|
+
get RecordProcess() {
|
|
84843
|
+
return this.Get('RecordProcess');
|
|
84844
|
+
}
|
|
84845
|
+
/**
|
|
84846
|
+
* * Field Name: Entity
|
|
84847
|
+
* * Display Name: Entity
|
|
84848
|
+
* * SQL Data Type: nvarchar(255)
|
|
84849
|
+
*/
|
|
84850
|
+
get Entity() {
|
|
84851
|
+
return this.Get('Entity');
|
|
84852
|
+
}
|
|
84853
|
+
/**
|
|
84854
|
+
* * Field Name: Prompt
|
|
84855
|
+
* * Display Name: Prompt
|
|
84856
|
+
* * SQL Data Type: nvarchar(255)
|
|
84857
|
+
*/
|
|
84858
|
+
get Prompt() {
|
|
84859
|
+
return this.Get('Prompt');
|
|
84860
|
+
}
|
|
84861
|
+
/**
|
|
84862
|
+
* * Field Name: ProcessRunDetail
|
|
84863
|
+
* * Display Name: Process Run Detail
|
|
84864
|
+
* * SQL Data Type: nvarchar(450)
|
|
84865
|
+
*/
|
|
84866
|
+
get ProcessRunDetail() {
|
|
84867
|
+
return this.Get('ProcessRunDetail');
|
|
84868
|
+
}
|
|
84869
|
+
/**
|
|
84870
|
+
* * Field Name: FeatureValueCache
|
|
84871
|
+
* * Display Name: Feature Value Cache
|
|
84872
|
+
* * SQL Data Type: nvarchar(500)
|
|
84873
|
+
*/
|
|
84874
|
+
get FeatureValueCache() {
|
|
84875
|
+
return this.Get('FeatureValueCache');
|
|
84876
|
+
}
|
|
84877
|
+
};
|
|
84878
|
+
MJFeatureValueEntity = __decorate([
|
|
84879
|
+
RegisterClass(BaseEntity, 'MJ: Feature Values')
|
|
84880
|
+
], MJFeatureValueEntity);
|
|
84881
|
+
export { MJFeatureValueEntity };
|
|
83807
84882
|
/**
|
|
83808
84883
|
* MJ: File Categories - strongly typed entity sub-class
|
|
83809
84884
|
* * Schema: __mj
|
|
@@ -95760,6 +96835,19 @@ let MJProjectEntity = class MJProjectEntity extends BaseEntity {
|
|
|
95760
96835
|
return this.Get('__mj_UpdatedAt');
|
|
95761
96836
|
}
|
|
95762
96837
|
/**
|
|
96838
|
+
* * Field Name: OwnerUserID
|
|
96839
|
+
* * Display Name: Owner User ID
|
|
96840
|
+
* * SQL Data Type: uniqueidentifier
|
|
96841
|
+
* * Related Entity/Foreign Key: MJ: Users (vwUsers.ID)
|
|
96842
|
+
* * Description: The user who owns this folder, or NULL when the folder is shared with the whole environment. NULL (the value every pre-existing folder carries) means SHARED: visible to anyone who can read projects in the environment, which was the only possible behaviour before this column existed. A set value means PERSONAL: the folder belongs to that user and consumers filter it to them, so it stays out of other people's sidebars. Personal is opt-in at create time; nothing is migrated.
|
|
96843
|
+
*/
|
|
96844
|
+
get OwnerUserID() {
|
|
96845
|
+
return this.Get('OwnerUserID');
|
|
96846
|
+
}
|
|
96847
|
+
set OwnerUserID(value) {
|
|
96848
|
+
this.Set('OwnerUserID', value);
|
|
96849
|
+
}
|
|
96850
|
+
/**
|
|
95763
96851
|
* * Field Name: Environment
|
|
95764
96852
|
* * Display Name: Environment
|
|
95765
96853
|
* * SQL Data Type: nvarchar(255)
|
|
@@ -95776,6 +96864,14 @@ let MJProjectEntity = class MJProjectEntity extends BaseEntity {
|
|
|
95776
96864
|
return this.Get('Parent');
|
|
95777
96865
|
}
|
|
95778
96866
|
/**
|
|
96867
|
+
* * Field Name: OwnerUser
|
|
96868
|
+
* * Display Name: Owner User
|
|
96869
|
+
* * SQL Data Type: nvarchar(100)
|
|
96870
|
+
*/
|
|
96871
|
+
get OwnerUser() {
|
|
96872
|
+
return this.Get('OwnerUser');
|
|
96873
|
+
}
|
|
96874
|
+
/**
|
|
95779
96875
|
* * Field Name: RootParentID
|
|
95780
96876
|
* * Display Name: Root Parent ID
|
|
95781
96877
|
* * SQL Data Type: uniqueidentifier
|
|
@@ -96017,6 +97113,11 @@ export { MJPublicLinkEntity };
|
|
|
96017
97113
|
* @public
|
|
96018
97114
|
*/
|
|
96019
97115
|
let MJQueryEntity = class MJQueryEntity extends BaseEntity {
|
|
97116
|
+
constructor() {
|
|
97117
|
+
super(...arguments);
|
|
97118
|
+
this._ConfigurationObject_cached = undefined;
|
|
97119
|
+
this._ConfigurationObject_lastRaw = null;
|
|
97120
|
+
}
|
|
96020
97121
|
/**
|
|
96021
97122
|
* Loads the MJ: Queries record from the database
|
|
96022
97123
|
* @param ID: string - primary key value to load the MJ: Queries record.
|
|
@@ -96388,6 +97489,37 @@ let MJQueryEntity = class MJQueryEntity extends BaseEntity {
|
|
|
96388
97489
|
this.Set('IsMaterialized', value);
|
|
96389
97490
|
}
|
|
96390
97491
|
/**
|
|
97492
|
+
* * Field Name: Configuration
|
|
97493
|
+
* * Display Name: Configuration
|
|
97494
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
97495
|
+
* * JSON Type: MJQueryEntity_IQueryConfiguration
|
|
97496
|
+
* * Description: Optional JSON configuration bag defining query-level policies and semantic capabilities (shape = IQueryConfiguration). Includes Priority (1-100) for ground-truth ranking in the semantic layer, LogExecution to control query execution logging, AlternativeQuestions for multi-phrasing vector recall, UsageGuidance and WhenNotToUse bounds for AI agents, and DomainScope.
|
|
97497
|
+
*/
|
|
97498
|
+
get Configuration() {
|
|
97499
|
+
return this.Get('Configuration');
|
|
97500
|
+
}
|
|
97501
|
+
set Configuration(value) {
|
|
97502
|
+
this.Set('Configuration', value);
|
|
97503
|
+
}
|
|
97504
|
+
/**
|
|
97505
|
+
* Typed accessor for Configuration — returns parsed JSON as MJQueryEntity_IQueryConfiguration.
|
|
97506
|
+
* Uses lazy parsing with cache invalidation when the underlying raw value changes.
|
|
97507
|
+
*/
|
|
97508
|
+
get ConfigurationObject() {
|
|
97509
|
+
const raw = this.Configuration;
|
|
97510
|
+
if (raw !== this._ConfigurationObject_lastRaw) {
|
|
97511
|
+
this._ConfigurationObject_cached = raw ? JSON.parse(raw) : null;
|
|
97512
|
+
this._ConfigurationObject_lastRaw = raw;
|
|
97513
|
+
}
|
|
97514
|
+
return this._ConfigurationObject_cached;
|
|
97515
|
+
}
|
|
97516
|
+
set ConfigurationObject(value) {
|
|
97517
|
+
const raw = value ? JSON.stringify(value) : null;
|
|
97518
|
+
this.Configuration = raw;
|
|
97519
|
+
this._ConfigurationObject_cached = value;
|
|
97520
|
+
this._ConfigurationObject_lastRaw = raw;
|
|
97521
|
+
}
|
|
97522
|
+
/**
|
|
96391
97523
|
* * Field Name: Category
|
|
96392
97524
|
* * Display Name: Category Name
|
|
96393
97525
|
* * SQL Data Type: nvarchar(50)
|
|
@@ -112075,6 +113207,11 @@ export { MJTestTypeEntity };
|
|
|
112075
113207
|
* @public
|
|
112076
113208
|
*/
|
|
112077
113209
|
let MJTestEntity = class MJTestEntity extends BaseEntity {
|
|
113210
|
+
constructor() {
|
|
113211
|
+
super(...arguments);
|
|
113212
|
+
this._ConfigurationObject_cached = undefined;
|
|
113213
|
+
this._ConfigurationObject_lastRaw = null;
|
|
113214
|
+
}
|
|
112078
113215
|
/**
|
|
112079
113216
|
* Loads the MJ: Tests record from the database
|
|
112080
113217
|
* @param ID: string - primary key value to load the MJ: Tests record.
|
|
@@ -112211,6 +113348,7 @@ let MJTestEntity = class MJTestEntity extends BaseEntity {
|
|
|
112211
113348
|
* * Field Name: Configuration
|
|
112212
113349
|
* * Display Name: Configuration
|
|
112213
113350
|
* * SQL Data Type: nvarchar(MAX)
|
|
113351
|
+
* * JSON Type: MJTestEntity_ITestConfiguration
|
|
112214
113352
|
* * Description: JSON object for test-specific configuration (e.g., oracles to use, rubrics, retry policies, timeout settings)
|
|
112215
113353
|
*/
|
|
112216
113354
|
get Configuration() {
|
|
@@ -112220,6 +113358,24 @@ let MJTestEntity = class MJTestEntity extends BaseEntity {
|
|
|
112220
113358
|
this.Set('Configuration', value);
|
|
112221
113359
|
}
|
|
112222
113360
|
/**
|
|
113361
|
+
* Typed accessor for Configuration — returns parsed JSON as MJTestEntity_ITestConfiguration.
|
|
113362
|
+
* Uses lazy parsing with cache invalidation when the underlying raw value changes.
|
|
113363
|
+
*/
|
|
113364
|
+
get ConfigurationObject() {
|
|
113365
|
+
const raw = this.Configuration;
|
|
113366
|
+
if (raw !== this._ConfigurationObject_lastRaw) {
|
|
113367
|
+
this._ConfigurationObject_cached = raw ? JSON.parse(raw) : null;
|
|
113368
|
+
this._ConfigurationObject_lastRaw = raw;
|
|
113369
|
+
}
|
|
113370
|
+
return this._ConfigurationObject_cached;
|
|
113371
|
+
}
|
|
113372
|
+
set ConfigurationObject(value) {
|
|
113373
|
+
const raw = value ? JSON.stringify(value) : null;
|
|
113374
|
+
this.Configuration = raw;
|
|
113375
|
+
this._ConfigurationObject_cached = value;
|
|
113376
|
+
this._ConfigurationObject_lastRaw = raw;
|
|
113377
|
+
}
|
|
113378
|
+
/**
|
|
112223
113379
|
* * Field Name: Tags
|
|
112224
113380
|
* * Display Name: Tags
|
|
112225
113381
|
* * SQL Data Type: nvarchar(MAX)
|
|
@@ -117171,6 +118327,267 @@ MJViewTypeEntity = __decorate([
|
|
|
117171
118327
|
RegisterClass(BaseEntity, 'MJ: View Types')
|
|
117172
118328
|
], MJViewTypeEntity);
|
|
117173
118329
|
export { MJViewTypeEntity };
|
|
118330
|
+
/**
|
|
118331
|
+
* MJ: Web Search Providers - strongly typed entity sub-class
|
|
118332
|
+
* * Schema: __mj
|
|
118333
|
+
* * Base Table: WebSearchProvider
|
|
118334
|
+
* * Base View: vwWebSearchProviders
|
|
118335
|
+
* * @description Registry of external web search vendors available to @memberjunction/web-search-engine. Each row configures one driver: whether it is active, its position in the failover order, and where its credential lives. Provider capabilities (answer synthesis, domain filtering, freshness) are declared by the driver class, not stored here.
|
|
118336
|
+
* * Primary Key: ID
|
|
118337
|
+
* @extends {BaseEntity}
|
|
118338
|
+
* @class
|
|
118339
|
+
* @public
|
|
118340
|
+
*/
|
|
118341
|
+
let MJWebSearchProviderEntity = class MJWebSearchProviderEntity extends BaseEntity {
|
|
118342
|
+
/**
|
|
118343
|
+
* Loads the MJ: Web Search Providers record from the database
|
|
118344
|
+
* @param ID: string - primary key value to load the MJ: Web Search Providers record.
|
|
118345
|
+
* @param EntityRelationshipsToLoad - (optional) the relationships to load
|
|
118346
|
+
* @returns {Promise<boolean>} - true if successful, false otherwise
|
|
118347
|
+
* @public
|
|
118348
|
+
* @async
|
|
118349
|
+
* @memberof MJWebSearchProviderEntity
|
|
118350
|
+
* @method
|
|
118351
|
+
* @override
|
|
118352
|
+
*/
|
|
118353
|
+
async Load(ID, EntityRelationshipsToLoad) {
|
|
118354
|
+
const compositeKey = new CompositeKey();
|
|
118355
|
+
compositeKey.KeyValuePairs.push({ FieldName: 'ID', Value: ID });
|
|
118356
|
+
return await super.InnerLoad(compositeKey, EntityRelationshipsToLoad);
|
|
118357
|
+
}
|
|
118358
|
+
/**
|
|
118359
|
+
* Validate() method override for MJ: Web Search Providers entity. This is an auto-generated method that invokes the generated validators for this entity for the following fields:
|
|
118360
|
+
* * MaxResultsOverride: The maximum results override must be greater than 0 if it is specified.
|
|
118361
|
+
* * Priority: The priority value must be a non-negative number (0 or greater) to ensure correct ordering and scheduling.
|
|
118362
|
+
* @public
|
|
118363
|
+
* @method
|
|
118364
|
+
* @override
|
|
118365
|
+
*/
|
|
118366
|
+
Validate() {
|
|
118367
|
+
const result = super.Validate();
|
|
118368
|
+
this.ValidateMaxResultsOverrideGreaterThanZero(result);
|
|
118369
|
+
this.ValidatePriorityMinVal(result);
|
|
118370
|
+
result.Success = result.Success && (result.Errors.length === 0);
|
|
118371
|
+
return result;
|
|
118372
|
+
}
|
|
118373
|
+
/**
|
|
118374
|
+
* The maximum results override must be greater than 0 if it is specified.
|
|
118375
|
+
* @param result - the ValidationResult object to add any errors or warnings to
|
|
118376
|
+
* @public
|
|
118377
|
+
* @method
|
|
118378
|
+
*/
|
|
118379
|
+
ValidateMaxResultsOverrideGreaterThanZero(result) {
|
|
118380
|
+
if (this.MaxResultsOverride != null && this.MaxResultsOverride <= 0) {
|
|
118381
|
+
result.Errors.push(new ValidationErrorInfo("MaxResultsOverride", "The maximum results override must be greater than 0 if it is specified.", this.MaxResultsOverride, ValidationErrorType.Failure));
|
|
118382
|
+
}
|
|
118383
|
+
}
|
|
118384
|
+
/**
|
|
118385
|
+
* The priority value must be a non-negative number (0 or greater) to ensure correct ordering and scheduling.
|
|
118386
|
+
* @param result - the ValidationResult object to add any errors or warnings to
|
|
118387
|
+
* @public
|
|
118388
|
+
* @method
|
|
118389
|
+
*/
|
|
118390
|
+
ValidatePriorityMinVal(result) {
|
|
118391
|
+
if (this.Priority < 0) {
|
|
118392
|
+
result.Errors.push(new ValidationErrorInfo("Priority", "Priority must be greater than or equal to 0.", this.Priority, ValidationErrorType.Failure));
|
|
118393
|
+
}
|
|
118394
|
+
}
|
|
118395
|
+
/**
|
|
118396
|
+
* * Field Name: ID
|
|
118397
|
+
* * Display Name: ID
|
|
118398
|
+
* * SQL Data Type: uniqueidentifier
|
|
118399
|
+
* * Default Value: newsequentialid()
|
|
118400
|
+
*/
|
|
118401
|
+
get ID() {
|
|
118402
|
+
return this.Get('ID');
|
|
118403
|
+
}
|
|
118404
|
+
set ID(value) {
|
|
118405
|
+
this.Set('ID', value);
|
|
118406
|
+
}
|
|
118407
|
+
/**
|
|
118408
|
+
* * Field Name: Name
|
|
118409
|
+
* * Display Name: Name
|
|
118410
|
+
* * SQL Data Type: nvarchar(200)
|
|
118411
|
+
* * Description: Administrator-facing name for this provider, e.g. "Brave" or "Tavily". Unique, and usable as the Provider value when a caller pins a search to one vendor.
|
|
118412
|
+
*/
|
|
118413
|
+
get Name() {
|
|
118414
|
+
return this.Get('Name');
|
|
118415
|
+
}
|
|
118416
|
+
set Name(value) {
|
|
118417
|
+
this.Set('Name', value);
|
|
118418
|
+
}
|
|
118419
|
+
/**
|
|
118420
|
+
* * Field Name: Description
|
|
118421
|
+
* * Display Name: Description
|
|
118422
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
118423
|
+
* * Description: What this provider searches, what it costs, and when it is the right choice.
|
|
118424
|
+
*/
|
|
118425
|
+
get Description() {
|
|
118426
|
+
return this.Get('Description');
|
|
118427
|
+
}
|
|
118428
|
+
set Description(value) {
|
|
118429
|
+
this.Set('Description', value);
|
|
118430
|
+
}
|
|
118431
|
+
/**
|
|
118432
|
+
* * Field Name: DriverClass
|
|
118433
|
+
* * Display Name: Driver Class
|
|
118434
|
+
* * SQL Data Type: nvarchar(500)
|
|
118435
|
+
* * Description: ClassFactory key used with @RegisterClass(BaseWebSearchProvider, DriverClass) to instantiate the driver at runtime, e.g. "BraveWebSearchProvider". A value with no matching registration leaves the provider unavailable and is logged at engine startup.
|
|
118436
|
+
*/
|
|
118437
|
+
get DriverClass() {
|
|
118438
|
+
return this.Get('DriverClass');
|
|
118439
|
+
}
|
|
118440
|
+
set DriverClass(value) {
|
|
118441
|
+
this.Set('DriverClass', value);
|
|
118442
|
+
}
|
|
118443
|
+
/**
|
|
118444
|
+
* * Field Name: Status
|
|
118445
|
+
* * Display Name: Status
|
|
118446
|
+
* * SQL Data Type: nvarchar(20)
|
|
118447
|
+
* * Default Value: Active
|
|
118448
|
+
* * Value List Type: List
|
|
118449
|
+
* * Possible Values
|
|
118450
|
+
* * Active
|
|
118451
|
+
* * Pending
|
|
118452
|
+
* * Terminated
|
|
118453
|
+
* * Description: Provider lifecycle status: Pending (configured but not yet in use), Active (participates in searches), Terminated (disabled). Only Active providers are loaded. Matches the vocabulary used by SearchProvider.
|
|
118454
|
+
*/
|
|
118455
|
+
get Status() {
|
|
118456
|
+
return this.Get('Status');
|
|
118457
|
+
}
|
|
118458
|
+
set Status(value) {
|
|
118459
|
+
this.Set('Status', value);
|
|
118460
|
+
}
|
|
118461
|
+
/**
|
|
118462
|
+
* * Field Name: Priority
|
|
118463
|
+
* * Display Name: Priority
|
|
118464
|
+
* * SQL Data Type: int
|
|
118465
|
+
* * Default Value: 0
|
|
118466
|
+
* * Description: Failover order: LOWER values are tried FIRST. The engine serves a search from the first available provider in this order, moving on only when one fails transiently. Must be >= 0.
|
|
118467
|
+
*/
|
|
118468
|
+
get Priority() {
|
|
118469
|
+
return this.Get('Priority');
|
|
118470
|
+
}
|
|
118471
|
+
set Priority(value) {
|
|
118472
|
+
this.Set('Priority', value);
|
|
118473
|
+
}
|
|
118474
|
+
/**
|
|
118475
|
+
* * Field Name: CredentialID
|
|
118476
|
+
* * Display Name: Credential ID
|
|
118477
|
+
* * SQL Data Type: uniqueidentifier
|
|
118478
|
+
* * Related Entity/Foreign Key: MJ: Credentials (vwCredentials.ID)
|
|
118479
|
+
* * Description: Optional FK to the Credential record holding this provider's API key. When NULL the driver falls back to its documented environment variable, so a host that has not yet migrated its secrets into the Credential store keeps working.
|
|
118480
|
+
*/
|
|
118481
|
+
get CredentialID() {
|
|
118482
|
+
return this.Get('CredentialID');
|
|
118483
|
+
}
|
|
118484
|
+
set CredentialID(value) {
|
|
118485
|
+
this.Set('CredentialID', value);
|
|
118486
|
+
}
|
|
118487
|
+
/**
|
|
118488
|
+
* * Field Name: ProviderConfig
|
|
118489
|
+
* * Display Name: Provider Config
|
|
118490
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
118491
|
+
* * Description: Optional JSON blob of non-secret, driver-specific settings (endpoint overrides, tier flags, answer model). Schema is defined by each driver; invalid JSON is logged and ignored rather than disabling the provider.
|
|
118492
|
+
*/
|
|
118493
|
+
get ProviderConfig() {
|
|
118494
|
+
return this.Get('ProviderConfig');
|
|
118495
|
+
}
|
|
118496
|
+
set ProviderConfig(value) {
|
|
118497
|
+
this.Set('ProviderConfig', value);
|
|
118498
|
+
}
|
|
118499
|
+
/**
|
|
118500
|
+
* * Field Name: MaxResultsOverride
|
|
118501
|
+
* * Display Name: Max Results Override
|
|
118502
|
+
* * SQL Data Type: int
|
|
118503
|
+
* * Description: Optional per-provider cap on results per request, for pay-per-query vendors. The effective cap is the smallest of the caller's request, this value, and the vendor's own hard limit. NULL means the driver's own limit applies.
|
|
118504
|
+
*/
|
|
118505
|
+
get MaxResultsOverride() {
|
|
118506
|
+
return this.Get('MaxResultsOverride');
|
|
118507
|
+
}
|
|
118508
|
+
set MaxResultsOverride(value) {
|
|
118509
|
+
this.Set('MaxResultsOverride', value);
|
|
118510
|
+
}
|
|
118511
|
+
/**
|
|
118512
|
+
* * Field Name: AllowResultCaching
|
|
118513
|
+
* * Display Name: Allow Result Caching
|
|
118514
|
+
* * SQL Data Type: bit
|
|
118515
|
+
* * Default Value: 0
|
|
118516
|
+
* * Description: Whether this vendor's terms permit storing returned results. Defaults to 0 (deny), because caching rights differ sharply between vendors and violating them is silent: some sell storage rights as a plan tier, others forbid persistent caching outright. Nothing in the engine caches today; this column exists so the first caching layer reads a per-provider gate instead of inventing one.
|
|
118517
|
+
*/
|
|
118518
|
+
get AllowResultCaching() {
|
|
118519
|
+
return this.Get('AllowResultCaching');
|
|
118520
|
+
}
|
|
118521
|
+
set AllowResultCaching(value) {
|
|
118522
|
+
this.Set('AllowResultCaching', value);
|
|
118523
|
+
}
|
|
118524
|
+
/**
|
|
118525
|
+
* * Field Name: DisplayName
|
|
118526
|
+
* * Display Name: Display Name
|
|
118527
|
+
* * SQL Data Type: nvarchar(200)
|
|
118528
|
+
* * Description: UI display name shown in admin surfaces and result attribution. When NULL, falls back to the Name column.
|
|
118529
|
+
*/
|
|
118530
|
+
get DisplayName() {
|
|
118531
|
+
return this.Get('DisplayName');
|
|
118532
|
+
}
|
|
118533
|
+
set DisplayName(value) {
|
|
118534
|
+
this.Set('DisplayName', value);
|
|
118535
|
+
}
|
|
118536
|
+
/**
|
|
118537
|
+
* * Field Name: Icon
|
|
118538
|
+
* * Display Name: Icon
|
|
118539
|
+
* * SQL Data Type: nvarchar(200)
|
|
118540
|
+
* * Description: CSS icon class for UI display, e.g. "fa-brands fa-brave". Supports any CSS-based icon library. When NULL a default icon is used.
|
|
118541
|
+
*/
|
|
118542
|
+
get Icon() {
|
|
118543
|
+
return this.Get('Icon');
|
|
118544
|
+
}
|
|
118545
|
+
set Icon(value) {
|
|
118546
|
+
this.Set('Icon', value);
|
|
118547
|
+
}
|
|
118548
|
+
/**
|
|
118549
|
+
* * Field Name: Comments
|
|
118550
|
+
* * Display Name: Comments
|
|
118551
|
+
* * SQL Data Type: nvarchar(MAX)
|
|
118552
|
+
* * Description: Free-form administrator notes, e.g. contract terms, billing owner, or why this provider sits at its priority.
|
|
118553
|
+
*/
|
|
118554
|
+
get Comments() {
|
|
118555
|
+
return this.Get('Comments');
|
|
118556
|
+
}
|
|
118557
|
+
set Comments(value) {
|
|
118558
|
+
this.Set('Comments', value);
|
|
118559
|
+
}
|
|
118560
|
+
/**
|
|
118561
|
+
* * Field Name: __mj_CreatedAt
|
|
118562
|
+
* * Display Name: Created At
|
|
118563
|
+
* * SQL Data Type: datetimeoffset
|
|
118564
|
+
* * Default Value: getutcdate()
|
|
118565
|
+
*/
|
|
118566
|
+
get __mj_CreatedAt() {
|
|
118567
|
+
return this.Get('__mj_CreatedAt');
|
|
118568
|
+
}
|
|
118569
|
+
/**
|
|
118570
|
+
* * Field Name: __mj_UpdatedAt
|
|
118571
|
+
* * Display Name: Updated At
|
|
118572
|
+
* * SQL Data Type: datetimeoffset
|
|
118573
|
+
* * Default Value: getutcdate()
|
|
118574
|
+
*/
|
|
118575
|
+
get __mj_UpdatedAt() {
|
|
118576
|
+
return this.Get('__mj_UpdatedAt');
|
|
118577
|
+
}
|
|
118578
|
+
/**
|
|
118579
|
+
* * Field Name: Credential
|
|
118580
|
+
* * Display Name: Credential
|
|
118581
|
+
* * SQL Data Type: nvarchar(200)
|
|
118582
|
+
*/
|
|
118583
|
+
get Credential() {
|
|
118584
|
+
return this.Get('Credential');
|
|
118585
|
+
}
|
|
118586
|
+
};
|
|
118587
|
+
MJWebSearchProviderEntity = __decorate([
|
|
118588
|
+
RegisterClass(BaseEntity, 'MJ: Web Search Providers')
|
|
118589
|
+
], MJWebSearchProviderEntity);
|
|
118590
|
+
export { MJWebSearchProviderEntity };
|
|
117174
118591
|
/**
|
|
117175
118592
|
* MJ: Workspace Items - strongly typed entity sub-class
|
|
117176
118593
|
* * Schema: __mj
|