@memberjunction/ng-core-entity-forms 2.51.0 → 2.52.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (54) hide show
  1. package/dist/lib/custom/AIAgents/ai-agent-form.component.js +1 -1
  2. package/dist/lib/custom/AIPrompts/ai-prompt-form.component.d.ts +0 -1
  3. package/dist/lib/custom/AIPrompts/ai-prompt-form.component.d.ts.map +1 -1
  4. package/dist/lib/custom/AIPrompts/ai-prompt-form.component.js +282 -278
  5. package/dist/lib/custom/AIPrompts/ai-prompt-form.component.js.map +1 -1
  6. package/dist/lib/custom/ai-test-harness/agent-execution-monitor.component.d.ts.map +1 -0
  7. package/dist/lib/custom/{AIAgents → ai-test-harness}/agent-execution-monitor.component.js +18 -5
  8. package/dist/lib/custom/ai-test-harness/agent-execution-monitor.component.js.map +1 -0
  9. package/dist/lib/custom/ai-test-harness/agent-execution-node.component.d.ts.map +1 -0
  10. package/dist/lib/custom/{AIAgents → ai-test-harness}/agent-execution-node.component.js +4 -4
  11. package/dist/lib/custom/ai-test-harness/agent-execution-node.component.js.map +1 -0
  12. package/dist/lib/custom/ai-test-harness/ai-test-harness-dialog.component.d.ts.map +1 -0
  13. package/dist/lib/custom/{AIAgents → ai-test-harness}/ai-test-harness-dialog.component.js +1 -1
  14. package/dist/lib/custom/ai-test-harness/ai-test-harness-dialog.component.js.map +1 -0
  15. package/dist/lib/custom/{AIAgents → ai-test-harness}/ai-test-harness.component.d.ts +88 -7
  16. package/dist/lib/custom/ai-test-harness/ai-test-harness.component.d.ts.map +1 -0
  17. package/dist/lib/custom/ai-test-harness/ai-test-harness.component.js +3140 -0
  18. package/dist/lib/custom/ai-test-harness/ai-test-harness.component.js.map +1 -0
  19. package/dist/lib/custom/ai-test-harness/json-viewer-window.component.d.ts +8 -0
  20. package/dist/lib/custom/ai-test-harness/json-viewer-window.component.d.ts.map +1 -0
  21. package/dist/lib/custom/ai-test-harness/json-viewer-window.component.js +57 -0
  22. package/dist/lib/custom/ai-test-harness/json-viewer-window.component.js.map +1 -0
  23. package/dist/lib/custom/custom-forms.module.d.ts +15 -15
  24. package/dist/lib/custom/custom-forms.module.js +8 -8
  25. package/dist/lib/custom/custom-forms.module.js.map +1 -1
  26. package/dist/lib/custom/test-harness-dialog.service.js +1 -1
  27. package/dist/lib/custom/test-harness-dialog.service.js.map +1 -1
  28. package/dist/lib/generated/Entities/AIPrompt/sections/details.component.d.ts.map +1 -1
  29. package/dist/lib/generated/Entities/AIPrompt/sections/details.component.js +94 -4
  30. package/dist/lib/generated/Entities/AIPrompt/sections/details.component.js.map +1 -1
  31. package/dist/lib/generated/Entities/AIPromptRun/sections/details.component.d.ts.map +1 -1
  32. package/dist/lib/generated/Entities/AIPromptRun/sections/details.component.js +103 -4
  33. package/dist/lib/generated/Entities/AIPromptRun/sections/details.component.js.map +1 -1
  34. package/dist/public-api.d.ts +2 -2
  35. package/dist/public-api.d.ts.map +1 -1
  36. package/dist/public-api.js +2 -2
  37. package/dist/public-api.js.map +1 -1
  38. package/package.json +12 -12
  39. package/dist/lib/custom/AIAgents/agent-execution-monitor.component.d.ts.map +0 -1
  40. package/dist/lib/custom/AIAgents/agent-execution-monitor.component.js.map +0 -1
  41. package/dist/lib/custom/AIAgents/agent-execution-node.component.d.ts.map +0 -1
  42. package/dist/lib/custom/AIAgents/agent-execution-node.component.js.map +0 -1
  43. package/dist/lib/custom/AIAgents/ai-test-harness-dialog.component.d.ts.map +0 -1
  44. package/dist/lib/custom/AIAgents/ai-test-harness-dialog.component.js.map +0 -1
  45. package/dist/lib/custom/AIAgents/ai-test-harness.component.d.ts.map +0 -1
  46. package/dist/lib/custom/AIAgents/ai-test-harness.component.js +0 -2658
  47. package/dist/lib/custom/AIAgents/ai-test-harness.component.js.map +0 -1
  48. package/dist/lib/custom/AIPrompts/ai-prompt-execution-dialog.component.d.ts +0 -99
  49. package/dist/lib/custom/AIPrompts/ai-prompt-execution-dialog.component.d.ts.map +0 -1
  50. package/dist/lib/custom/AIPrompts/ai-prompt-execution-dialog.component.js +0 -830
  51. package/dist/lib/custom/AIPrompts/ai-prompt-execution-dialog.component.js.map +0 -1
  52. /package/dist/lib/custom/{AIAgents → ai-test-harness}/agent-execution-monitor.component.d.ts +0 -0
  53. /package/dist/lib/custom/{AIAgents → ai-test-harness}/agent-execution-node.component.d.ts +0 -0
  54. /package/dist/lib/custom/{AIAgents → ai-test-harness}/ai-test-harness-dialog.component.d.ts +0 -0
@@ -28,8 +28,7 @@ import * as i12 from "@memberjunction/ng-form-toolbar";
28
28
  import * as i13 from "@memberjunction/ng-container-directives";
29
29
  import * as i14 from "@memberjunction/ng-code-editor";
30
30
  import * as i15 from "../../shared/components/template-editor.component";
31
- import * as i16 from "./ai-prompt-execution-dialog.component";
32
- import * as i17 from "../AIAgents/ai-test-harness.component";
31
+ import * as i16 from "../ai-test-harness/ai-test-harness.component";
33
32
  const _c0 = ["templateEditor"];
34
33
  const _forTrack0 = ($index, $item) => $item.ID || $index;
35
34
  const _forTrack1 = ($index, $item) => $item.ID;
@@ -42,7 +41,7 @@ const _c6 = () => ({ text: "Static Count", value: "StaticCount" });
42
41
  const _c7 = () => ({ text: "Config Param", value: "ConfigParam" });
43
42
  function AIPromptFormComponentExtended_form_1_Conditional_9_Template(rf, ctx) { if (rf & 1) {
44
43
  const _r1 = i0.ɵɵgetCurrentView();
45
- i0.ɵɵelementStart(0, "kendo-textbox", 48);
44
+ i0.ɵɵelementStart(0, "kendo-textbox", 47);
46
45
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_9_Template_kendo_textbox_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r1); const ctx_r1 = i0.ɵɵnextContext(2); i0.ɵɵtwoWayBindingSet(ctx_r1.record.Name, $event) || (ctx_r1.record.Name = $event); return i0.ɵɵresetView($event); });
47
46
  i0.ɵɵelementEnd();
48
47
  } if (rf & 2) {
@@ -50,10 +49,10 @@ function AIPromptFormComponentExtended_form_1_Conditional_9_Template(rf, ctx) {
50
49
  i0.ɵɵtwoWayProperty("ngModel", ctx_r1.record.Name);
51
50
  } }
52
51
  function AIPromptFormComponentExtended_form_1_Conditional_10_Template(rf, ctx) { if (rf & 1) {
53
- i0.ɵɵelementStart(0, "h4", 49);
52
+ i0.ɵɵelementStart(0, "h4", 48);
54
53
  i0.ɵɵtext(1);
55
54
  i0.ɵɵelementEnd();
56
- i0.ɵɵelementStart(2, "span", 50);
55
+ i0.ɵɵelementStart(2, "span", 49);
57
56
  i0.ɵɵtext(3);
58
57
  i0.ɵɵelementEnd();
59
58
  } if (rf & 2) {
@@ -66,14 +65,14 @@ function AIPromptFormComponentExtended_form_1_Conditional_10_Template(rf, ctx) {
66
65
  i0.ɵɵtextInterpolate1(" ", ctx_r1.record.Status, " ");
67
66
  } }
68
67
  function AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_10_Template(rf, ctx) { if (rf & 1) {
69
- i0.ɵɵelementStart(0, "div", 53);
70
- i0.ɵɵelement(1, "i", 55);
68
+ i0.ɵɵelementStart(0, "div", 52);
69
+ i0.ɵɵelement(1, "i", 54);
71
70
  i0.ɵɵtext(2, " Loading types... ");
72
71
  i0.ɵɵelementEnd();
73
72
  } }
74
73
  function AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_11_Template(rf, ctx) { if (rf & 1) {
75
74
  const _r4 = i0.ɵɵgetCurrentView();
76
- i0.ɵɵelementStart(0, "kendo-dropdownlist", 56);
75
+ i0.ɵɵelementStart(0, "kendo-dropdownlist", 55);
77
76
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_11_Template_kendo_dropdownlist_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r4); const ctx_r1 = i0.ɵɵnextContext(3); i0.ɵɵtwoWayBindingSet(ctx_r1.record.TypeID, $event) || (ctx_r1.record.TypeID = $event); return i0.ɵɵresetView($event); });
78
77
  i0.ɵɵelementEnd();
79
78
  } if (rf & 2) {
@@ -83,18 +82,18 @@ function AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_11_Temp
83
82
  } }
84
83
  function AIPromptFormComponentExtended_form_1_Conditional_11_Template(rf, ctx) { if (rf & 1) {
85
84
  const _r3 = i0.ɵɵgetCurrentView();
86
- i0.ɵɵelementStart(0, "div", 15)(1, "div")(2, "label", 46);
85
+ i0.ɵɵelementStart(0, "div", 14)(1, "div")(2, "label", 45);
87
86
  i0.ɵɵtext(3, "Status");
88
87
  i0.ɵɵelementEnd();
89
- i0.ɵɵelementStart(4, "kendo-dropdownlist", 51);
88
+ i0.ɵɵelementStart(4, "kendo-dropdownlist", 50);
90
89
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_11_Template_kendo_dropdownlist_ngModelChange_4_listener($event) { i0.ɵɵrestoreView(_r3); const ctx_r1 = i0.ɵɵnextContext(2); i0.ɵɵtwoWayBindingSet(ctx_r1.record.Status, $event) || (ctx_r1.record.Status = $event); return i0.ɵɵresetView($event); });
91
90
  i0.ɵɵelementEnd()();
92
- i0.ɵɵelementStart(5, "div")(6, "label", 46);
91
+ i0.ɵɵelementStart(5, "div")(6, "label", 45);
93
92
  i0.ɵɵtext(7, " Type ");
94
- i0.ɵɵelementStart(8, "span", 52);
93
+ i0.ɵɵelementStart(8, "span", 51);
95
94
  i0.ɵɵtext(9, "*");
96
95
  i0.ɵɵelementEnd()();
97
- i0.ɵɵtemplate(10, AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_10_Template, 3, 0, "div", 53)(11, AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_11_Template, 1, 4, "kendo-dropdownlist", 54);
96
+ i0.ɵɵtemplate(10, AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_10_Template, 3, 0, "div", 52)(11, AIPromptFormComponentExtended_form_1_Conditional_11_Conditional_11_Template, 1, 4, "kendo-dropdownlist", 53);
98
97
  i0.ɵɵelementEnd()();
99
98
  } if (rf & 2) {
100
99
  const ctx_r1 = i0.ɵɵnextContext(2);
@@ -106,7 +105,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_11_Template(rf, ctx) {
106
105
  } }
107
106
  function AIPromptFormComponentExtended_form_1_Conditional_12_Template(rf, ctx) { if (rf & 1) {
108
107
  const _r5 = i0.ɵɵgetCurrentView();
109
- i0.ɵɵelementStart(0, "kendo-textarea", 57);
108
+ i0.ɵɵelementStart(0, "kendo-textarea", 56);
110
109
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_12_Template_kendo_textarea_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r5); const ctx_r1 = i0.ɵɵnextContext(2); i0.ɵɵtwoWayBindingSet(ctx_r1.record.Description, $event) || (ctx_r1.record.Description = $event); return i0.ɵɵresetView($event); });
111
110
  i0.ɵɵelementEnd();
112
111
  } if (rf & 2) {
@@ -115,7 +114,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_12_Template(rf, ctx) {
115
114
  i0.ɵɵproperty("rows", 2);
116
115
  } }
117
116
  function AIPromptFormComponentExtended_form_1_Conditional_13_Template(rf, ctx) { if (rf & 1) {
118
- i0.ɵɵelementStart(0, "p", 17);
117
+ i0.ɵɵelementStart(0, "p", 16);
119
118
  i0.ɵɵtext(1);
120
119
  i0.ɵɵelementEnd();
121
120
  } if (rf & 2) {
@@ -124,12 +123,12 @@ function AIPromptFormComponentExtended_form_1_Conditional_13_Template(rf, ctx) {
124
123
  i0.ɵɵtextInterpolate(ctx_r1.record.Description);
125
124
  } }
126
125
  function AIPromptFormComponentExtended_form_1_Conditional_15_Template(rf, ctx) { if (rf & 1) {
127
- i0.ɵɵelementStart(0, "div", 19);
128
- i0.ɵɵelement(1, "i", 58);
129
- i0.ɵɵelementStart(2, "span", 21);
126
+ i0.ɵɵelementStart(0, "div", 18);
127
+ i0.ɵɵelement(1, "i", 57);
128
+ i0.ɵɵelementStart(2, "span", 20);
130
129
  i0.ɵɵtext(3, "Type:");
131
130
  i0.ɵɵelementEnd();
132
- i0.ɵɵelementStart(4, "span", 22);
131
+ i0.ɵɵelementStart(4, "span", 21);
133
132
  i0.ɵɵtext(5);
134
133
  i0.ɵɵelementEnd()();
135
134
  } if (rf & 2) {
@@ -138,19 +137,21 @@ function AIPromptFormComponentExtended_form_1_Conditional_15_Template(rf, ctx) {
138
137
  i0.ɵɵtextInterpolate(ctx_r1.getPromptTypeDisplayName(ctx_r1.record.TypeID));
139
138
  } }
140
139
  function AIPromptFormComponentExtended_form_1_Conditional_28_Template(rf, ctx) { if (rf & 1) {
141
- i0.ɵɵelementStart(0, "div", 19);
142
- i0.ɵɵelement(1, "i", 59);
143
- i0.ɵɵelementStart(2, "span", 60);
140
+ i0.ɵɵelementStart(0, "div", 18);
141
+ i0.ɵɵelement(1, "i", 58);
142
+ i0.ɵɵelementStart(2, "span", 59);
144
143
  i0.ɵɵtext(3, "Caching Enabled");
145
144
  i0.ɵɵelementEnd()();
146
145
  } }
147
146
  function AIPromptFormComponentExtended_form_1_Conditional_31_Template(rf, ctx) { if (rf & 1) {
148
147
  const _r6 = i0.ɵɵgetCurrentView();
149
- i0.ɵɵelementStart(0, "kendo-button", 61);
150
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_31_Template_kendo_button_click_0_listener() { i0.ɵɵrestoreView(_r6); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.openTestHarness()); });
151
- i0.ɵɵelement(1, "i", 62);
148
+ i0.ɵɵelementStart(0, "button", 60);
149
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_31_Template_button_click_0_listener() { i0.ɵɵrestoreView(_r6); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.openTestHarness()); });
150
+ i0.ɵɵelement(1, "i", 61);
152
151
  i0.ɵɵtext(2, " Run ");
153
152
  i0.ɵɵelementEnd();
153
+ } if (rf & 2) {
154
+ i0.ɵɵproperty("themeColor", "primary")("size", "large");
154
155
  } }
155
156
  function AIPromptFormComponentExtended_form_1_Conditional_32_Conditional_1_Template(rf, ctx) { if (rf & 1) {
156
157
  i0.ɵɵtext(0, " \u2022 Prompt must be Active");
@@ -165,7 +166,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_32_Conditional_3_Templ
165
166
  i0.ɵɵelement(1, "br");
166
167
  } }
167
168
  function AIPromptFormComponentExtended_form_1_Conditional_32_Template(rf, ctx) { if (rf & 1) {
168
- i0.ɵɵelementStart(0, "div", 28);
169
+ i0.ɵɵelementStart(0, "div", 27);
169
170
  i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_32_Conditional_1_Template, 2, 0, "br")(2, AIPromptFormComponentExtended_form_1_Conditional_32_Conditional_2_Template, 2, 0, "br")(3, AIPromptFormComponentExtended_form_1_Conditional_32_Conditional_3_Template, 2, 0, "br");
170
171
  i0.ɵɵelementEnd();
171
172
  } if (rf & 2) {
@@ -178,7 +179,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_32_Template(rf, ctx) {
178
179
  i0.ɵɵconditional(!ctx_r1.template && ctx_r1.record.TemplateID ? 3 : -1);
179
180
  } }
180
181
  function AIPromptFormComponentExtended_form_1_ng_template_35_Conditional_3_Template(rf, ctx) { if (rf & 1) {
181
- i0.ɵɵelementStart(0, "span", 64);
182
+ i0.ɵɵelementStart(0, "span", 63);
182
183
  i0.ɵɵtext(1);
183
184
  i0.ɵɵelementEnd();
184
185
  } if (rf & 2) {
@@ -187,10 +188,10 @@ function AIPromptFormComponentExtended_form_1_ng_template_35_Conditional_3_Templ
187
188
  i0.ɵɵtextInterpolate1("\u2022 ", ctx_r1.template.Name, "");
188
189
  } }
189
190
  function AIPromptFormComponentExtended_form_1_ng_template_35_Template(rf, ctx) { if (rf & 1) {
190
- i0.ɵɵelementStart(0, "span", 63);
191
- i0.ɵɵelement(1, "i", 23);
191
+ i0.ɵɵelementStart(0, "span", 62);
192
+ i0.ɵɵelement(1, "i", 22);
192
193
  i0.ɵɵtext(2, " Template Editor ");
193
- i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_ng_template_35_Conditional_3_Template, 2, 1, "span", 64);
194
+ i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_ng_template_35_Conditional_3_Template, 2, 1, "span", 63);
194
195
  i0.ɵɵelementEnd();
195
196
  } if (rf & 2) {
196
197
  const ctx_r1 = i0.ɵɵnextContext(2);
@@ -198,56 +199,66 @@ function AIPromptFormComponentExtended_form_1_ng_template_35_Template(rf, ctx) {
198
199
  i0.ɵɵconditional(ctx_r1.template ? 3 : -1);
199
200
  } }
200
201
  function AIPromptFormComponentExtended_form_1_Conditional_37_Template(rf, ctx) { if (rf & 1) {
201
- i0.ɵɵelementStart(0, "div", 33);
202
- i0.ɵɵelement(1, "i", 65);
202
+ i0.ɵɵelementStart(0, "div", 32);
203
+ i0.ɵɵelement(1, "i", 64);
203
204
  i0.ɵɵtext(2, " Loading template... ");
204
205
  i0.ɵɵelementEnd();
205
206
  } }
206
207
  function AIPromptFormComponentExtended_form_1_Conditional_38_Template(rf, ctx) { if (rf & 1) {
207
208
  const _r7 = i0.ɵɵgetCurrentView();
208
- i0.ɵɵelementStart(0, "div", 34);
209
- i0.ɵɵelement(1, "i", 66);
210
- i0.ɵɵelementStart(2, "h5", 67);
209
+ i0.ɵɵelementStart(0, "div", 33);
210
+ i0.ɵɵelement(1, "i", 65);
211
+ i0.ɵɵelementStart(2, "h5", 66);
211
212
  i0.ɵɵtext(3, "No Template Associated");
212
213
  i0.ɵɵelementEnd();
213
- i0.ɵɵelementStart(4, "p", 68);
214
+ i0.ɵɵelementStart(4, "p", 67);
214
215
  i0.ɵɵtext(5, " This AI prompt needs a template to define its structure and parameters. Create a new template or link to an existing one. ");
215
216
  i0.ɵɵelementEnd();
216
- i0.ɵɵelementStart(6, "div", 69)(7, "kendo-button", 70);
217
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_38_Template_kendo_button_click_7_listener() { i0.ɵɵrestoreView(_r7); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.createNewTemplate()); });
218
- i0.ɵɵelement(8, "i", 71);
217
+ i0.ɵɵelementStart(6, "div", 68)(7, "button", 69);
218
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_38_Template_button_click_7_listener() { i0.ɵɵrestoreView(_r7); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.createNewTemplate()); });
219
+ i0.ɵɵelement(8, "i", 70);
219
220
  i0.ɵɵtext(9, " Create New Template ");
220
221
  i0.ɵɵelementEnd();
221
- i0.ɵɵelementStart(10, "kendo-button", 72);
222
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_38_Template_kendo_button_click_10_listener() { i0.ɵɵrestoreView(_r7); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.linkExistingTemplate()); });
223
- i0.ɵɵelement(11, "i", 73);
222
+ i0.ɵɵelementStart(10, "button", 71);
223
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_38_Template_button_click_10_listener() { i0.ɵɵrestoreView(_r7); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.linkExistingTemplate()); });
224
+ i0.ɵɵelement(11, "i", 72);
224
225
  i0.ɵɵtext(12, " Link Existing Template ");
225
226
  i0.ɵɵelementEnd()()();
227
+ } if (rf & 2) {
228
+ i0.ɵɵadvance(7);
229
+ i0.ɵɵproperty("themeColor", "primary");
230
+ i0.ɵɵadvance(3);
231
+ i0.ɵɵproperty("fillMode", "outline");
226
232
  } }
227
233
  function AIPromptFormComponentExtended_form_1_Conditional_39_Template(rf, ctx) { if (rf & 1) {
228
234
  const _r8 = i0.ɵɵgetCurrentView();
229
- i0.ɵɵelementStart(0, "div", 35);
230
- i0.ɵɵelement(1, "i", 74);
231
- i0.ɵɵelementStart(2, "h5", 75);
235
+ i0.ɵɵelementStart(0, "div", 34);
236
+ i0.ɵɵelement(1, "i", 73);
237
+ i0.ɵɵelementStart(2, "h5", 74);
232
238
  i0.ɵɵtext(3, "Template Not Found");
233
239
  i0.ɵɵelementEnd();
234
- i0.ɵɵelementStart(4, "p", 68);
240
+ i0.ɵɵelementStart(4, "p", 67);
235
241
  i0.ɵɵtext(5, " The referenced template could not be loaded. It may have been deleted or moved. ");
236
242
  i0.ɵɵelementEnd();
237
- i0.ɵɵelementStart(6, "div", 69)(7, "kendo-button", 72);
238
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_39_Template_kendo_button_click_7_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.loadTemplate()); });
239
- i0.ɵɵelement(8, "i", 76);
243
+ i0.ɵɵelementStart(6, "div", 68)(7, "button", 71);
244
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_39_Template_button_click_7_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.loadTemplate()); });
245
+ i0.ɵɵelement(8, "i", 75);
240
246
  i0.ɵɵtext(9, " Retry Loading ");
241
247
  i0.ɵɵelementEnd();
242
- i0.ɵɵelementStart(10, "kendo-button", 70);
243
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_39_Template_kendo_button_click_10_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.createNewTemplate()); });
244
- i0.ɵɵelement(11, "i", 71);
248
+ i0.ɵɵelementStart(10, "button", 69);
249
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_39_Template_button_click_10_listener() { i0.ɵɵrestoreView(_r8); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.createNewTemplate()); });
250
+ i0.ɵɵelement(11, "i", 70);
245
251
  i0.ɵɵtext(12, " Create New Template ");
246
252
  i0.ɵɵelementEnd()()();
253
+ } if (rf & 2) {
254
+ i0.ɵɵadvance(7);
255
+ i0.ɵɵproperty("fillMode", "outline");
256
+ i0.ɵɵadvance(3);
257
+ i0.ɵɵproperty("themeColor", "primary");
247
258
  } }
248
259
  function AIPromptFormComponentExtended_form_1_Conditional_40_Template(rf, ctx) { if (rf & 1) {
249
260
  const _r9 = i0.ɵɵgetCurrentView();
250
- i0.ɵɵelementStart(0, "div", 36)(1, "div", 77)(2, "mj-template-editor", 78, 1);
261
+ i0.ɵɵelementStart(0, "div", 35)(1, "div", 76)(2, "mj-template-editor", 77, 1);
251
262
  i0.ɵɵlistener("contentChange", function AIPromptFormComponentExtended_form_1_Conditional_40_Template_mj_template_editor_contentChange_2_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.onTemplateContentChange($event)); })("runTemplate", function AIPromptFormComponentExtended_form_1_Conditional_40_Template_mj_template_editor_runTemplate_2_listener($event) { i0.ɵɵrestoreView(_r9); const ctx_r1 = i0.ɵɵnextContext(2); return i0.ɵɵresetView(ctx_r1.onTemplateRun($event)); });
252
263
  i0.ɵɵelementEnd()()();
253
264
  } if (rf & 2) {
@@ -256,7 +267,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_40_Template(rf, ctx) {
256
267
  i0.ɵɵproperty("template", ctx_r1.template)("config", ctx_r1.templateEditorConfig);
257
268
  } }
258
269
  function AIPromptFormComponentExtended_form_1_Conditional_41_ng_template_1_Conditional_3_Template(rf, ctx) { if (rf & 1) {
259
- i0.ɵɵelementStart(0, "span", 82);
270
+ i0.ɵɵelementStart(0, "span", 81);
260
271
  i0.ɵɵtext(1);
261
272
  i0.ɵɵelementEnd();
262
273
  } if (rf & 2) {
@@ -265,12 +276,12 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_ng_template_1_Condi
265
276
  i0.ɵɵtextInterpolate1(" ", ctx_r1.promptModels.length, " ");
266
277
  } }
267
278
  function AIPromptFormComponentExtended_form_1_Conditional_41_ng_template_1_Template(rf, ctx) { if (rf & 1) {
268
- i0.ɵɵelementStart(0, "span", 63);
269
- i0.ɵɵelement(1, "i", 81);
279
+ i0.ɵɵelementStart(0, "span", 62);
280
+ i0.ɵɵelement(1, "i", 80);
270
281
  i0.ɵɵtext(2, " Models ");
271
- i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_41_ng_template_1_Conditional_3_Template, 2, 1, "span", 82);
272
- i0.ɵɵelementStart(4, "span", 83);
273
- i0.ɵɵelement(5, "i", 84);
282
+ i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_41_ng_template_1_Conditional_3_Template, 2, 1, "span", 81);
283
+ i0.ɵɵelementStart(4, "span", 82);
284
+ i0.ɵɵelement(5, "i", 83);
274
285
  i0.ɵɵtext(6, " Priority order (first available model will be used) ");
275
286
  i0.ɵɵelementEnd()();
276
287
  } if (rf & 2) {
@@ -279,24 +290,24 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_ng_template_1_Templ
279
290
  i0.ɵɵconditional(ctx_r1.promptModels.length > 0 ? 3 : -1);
280
291
  } }
281
292
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_4_Template(rf, ctx) { if (rf & 1) {
282
- i0.ɵɵelementStart(0, "div", 80);
283
- i0.ɵɵelement(1, "i", 55);
293
+ i0.ɵɵelementStart(0, "div", 79);
294
+ i0.ɵɵelement(1, "i", 54);
284
295
  i0.ɵɵtext(2, " Loading models... ");
285
296
  i0.ɵɵelementEnd();
286
297
  } }
287
298
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_0_Conditional_3_Template(rf, ctx) { if (rf & 1) {
288
299
  const _r10 = i0.ɵɵgetCurrentView();
289
- i0.ɵɵelementStart(0, "div", 87)(1, "kendo-button", 88);
290
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_0_Conditional_3_Template_kendo_button_click_1_listener() { i0.ɵɵrestoreView(_r10); const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.addNewModel()); });
291
- i0.ɵɵelement(2, "i", 71);
300
+ i0.ɵɵelementStart(0, "div", 86)(1, "button", 87);
301
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_0_Conditional_3_Template_button_click_1_listener() { i0.ɵɵrestoreView(_r10); const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.addNewModel()); });
302
+ i0.ɵɵelement(2, "i", 70);
292
303
  i0.ɵɵtext(3, " Add Model ");
293
304
  i0.ɵɵelementEnd()();
294
305
  } }
295
306
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_0_Template(rf, ctx) { if (rf & 1) {
296
- i0.ɵɵelementStart(0, "div", 85);
297
- i0.ɵɵelement(1, "i", 86);
307
+ i0.ɵɵelementStart(0, "div", 84);
308
+ i0.ɵɵelement(1, "i", 85);
298
309
  i0.ɵɵtext(2, " No models configured ");
299
- i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_0_Conditional_3_Template, 4, 0, "div", 87);
310
+ i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_0_Conditional_3_Template, 4, 0, "div", 86);
300
311
  i0.ɵɵelementEnd();
301
312
  } if (rf & 2) {
302
313
  const ctx_r1 = i0.ɵɵnextContext(4);
@@ -304,14 +315,14 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
304
315
  i0.ɵɵconditional(ctx_r1.EditMode ? 3 : -1);
305
316
  } }
306
317
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Conditional_0_Template(rf, ctx) { if (rf & 1) {
307
- i0.ɵɵelementStart(0, "div", 89);
308
- i0.ɵɵelement(1, "i", 94);
318
+ i0.ɵɵelementStart(0, "div", 88);
319
+ i0.ɵɵelement(1, "i", 93);
309
320
  i0.ɵɵtext(2, " Models are tried in priority order (1, 2, 3...). The first available model that meets requirements will be used for execution. ");
310
321
  i0.ɵɵelementEnd();
311
322
  } }
312
323
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_2_Template(rf, ctx) { if (rf & 1) {
313
- i0.ɵɵelement(0, "i", 108);
314
- i0.ɵɵelementStart(1, "span", 109);
324
+ i0.ɵɵelement(0, "i", 107);
325
+ i0.ɵɵelementStart(1, "span", 108);
315
326
  i0.ɵɵtext(2);
316
327
  i0.ɵɵelementEnd();
317
328
  } if (rf & 2) {
@@ -320,7 +331,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
320
331
  i0.ɵɵtextInterpolate1("#", ɵ$index_279_r12 + 1, "");
321
332
  } }
322
333
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_3_Template(rf, ctx) { if (rf & 1) {
323
- i0.ɵɵelementStart(0, "span", 97);
334
+ i0.ɵɵelementStart(0, "span", 96);
324
335
  i0.ɵɵtext(1);
325
336
  i0.ɵɵelementEnd();
326
337
  } if (rf & 2) {
@@ -331,7 +342,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
331
342
  } }
332
343
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_5_Template(rf, ctx) { if (rf & 1) {
333
344
  const _r13 = i0.ɵɵgetCurrentView();
334
- i0.ɵɵelementStart(0, "kendo-dropdownlist", 110);
345
+ i0.ɵɵelementStart(0, "kendo-dropdownlist", 109);
335
346
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_5_Template_kendo_dropdownlist_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r13); const model_r14 = i0.ɵɵnextContext().$implicit; i0.ɵɵtwoWayBindingSet(model_r14.ModelID, $event) || (model_r14.ModelID = $event); return i0.ɵɵresetView($event); });
336
347
  i0.ɵɵlistener("valueChange", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_5_Template_kendo_dropdownlist_valueChange_0_listener($event) { i0.ɵɵrestoreView(_r13); const ɵ$index_279_r12 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.onModelChange($event, ɵ$index_279_r12)); });
337
348
  i0.ɵɵelementEnd();
@@ -344,7 +355,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
344
355
  i0.ɵɵproperty("name", "modelId_" + ɵ$index_279_r12)("data", ctx_r1.availableModels)("valuePrimitive", true)("filterable", true);
345
356
  } }
346
357
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_6_Template(rf, ctx) { if (rf & 1) {
347
- i0.ɵɵelementStart(0, "span", 24);
358
+ i0.ɵɵelementStart(0, "span", 23);
348
359
  i0.ɵɵtext(1);
349
360
  i0.ɵɵelementEnd();
350
361
  } if (rf & 2) {
@@ -354,7 +365,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
354
365
  i0.ɵɵtextInterpolate(ctx_r1.getModelDisplayName(model_r14.ModelID));
355
366
  } }
356
367
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_0_ng_template_1_Conditional_2_Template(rf, ctx) { if (rf & 1) {
357
- i0.ɵɵelementStart(0, "span", 115);
368
+ i0.ɵɵelementStart(0, "span", 114);
358
369
  i0.ɵɵtext(1);
359
370
  i0.ɵɵelementEnd();
360
371
  } if (rf & 2) {
@@ -367,7 +378,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
367
378
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_0_ng_template_1_Template(rf, ctx) { if (rf & 1) {
368
379
  i0.ɵɵelementStart(0, "span");
369
380
  i0.ɵɵtext(1);
370
- i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_0_ng_template_1_Conditional_2_Template, 2, 1, "span", 115);
381
+ i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_0_ng_template_1_Conditional_2_Template, 2, 1, "span", 114);
371
382
  i0.ɵɵelementEnd();
372
383
  } if (rf & 2) {
373
384
  const dataItem_r17 = ctx.$implicit;
@@ -381,9 +392,9 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
381
392
  } }
382
393
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_0_Template(rf, ctx) { if (rf & 1) {
383
394
  const _r16 = i0.ɵɵgetCurrentView();
384
- i0.ɵɵelementStart(0, "kendo-dropdownlist", 113);
395
+ i0.ɵɵelementStart(0, "kendo-dropdownlist", 112);
385
396
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_0_Template_kendo_dropdownlist_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r16); const model_r14 = i0.ɵɵnextContext(3).$implicit; i0.ɵɵtwoWayBindingSet(model_r14.VendorID, $event) || (model_r14.VendorID = $event); return i0.ɵɵresetView($event); });
386
- i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_0_ng_template_1_Template, 3, 4, "ng-template", 114);
397
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_0_ng_template_1_Template, 3, 4, "ng-template", 113);
387
398
  i0.ɵɵelementEnd();
388
399
  } if (rf & 2) {
389
400
  const ctx_r14 = i0.ɵɵnextContext(3);
@@ -394,7 +405,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
394
405
  i0.ɵɵproperty("name", "vendorId_" + ɵ$index_279_r12)("data", ctx_r1.getVendorsForModelSync(model_r14.ModelID))("valuePrimitive", true)("filterable", true);
395
406
  } }
396
407
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Conditional_0_Conditional_2_Template(rf, ctx) { if (rf & 1) {
397
- i0.ɵɵelementStart(0, "span", 115);
408
+ i0.ɵɵelementStart(0, "span", 114);
398
409
  i0.ɵɵtext(1);
399
410
  i0.ɵɵelementEnd();
400
411
  } if (rf & 2) {
@@ -404,9 +415,9 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
404
415
  i0.ɵɵtextInterpolate1("(", ctx_r1.getModelVendorStatus(model_r14.ModelID, ctx_r1.getVendorsForModelSync(model_r14.ModelID)[0].ID), ")");
405
416
  } }
406
417
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Conditional_0_Template(rf, ctx) { if (rf & 1) {
407
- i0.ɵɵelementStart(0, "span", 117);
418
+ i0.ɵɵelementStart(0, "span", 116);
408
419
  i0.ɵɵtext(1);
409
- i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Conditional_0_Conditional_2_Template, 2, 1, "span", 115);
420
+ i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Conditional_0_Conditional_2_Template, 2, 1, "span", 114);
410
421
  i0.ɵɵelementEnd();
411
422
  } if (rf & 2) {
412
423
  const model_r14 = i0.ɵɵnextContext(4).$implicit;
@@ -418,37 +429,37 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
418
429
  i0.ɵɵconditional(ctx_r1.getModelVendorStatus(model_r14.ModelID, ctx_r1.getVendorsForModelSync(model_r14.ModelID)[0].ID) !== "Active" ? 2 : -1);
419
430
  } }
420
431
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Conditional_1_Template(rf, ctx) { if (rf & 1) {
421
- i0.ɵɵelementStart(0, "span", 111);
432
+ i0.ɵɵelementStart(0, "span", 110);
422
433
  i0.ɵɵtext(1, "No vendors available");
423
434
  i0.ɵɵelementEnd();
424
435
  } }
425
436
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Template(rf, ctx) { if (rf & 1) {
426
- i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Conditional_0_Template, 3, 4, "span", 116)(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Conditional_1_Template, 2, 0, "span", 111);
437
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Conditional_0_Template, 3, 4, "span", 115)(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Conditional_1_Template, 2, 0, "span", 110);
427
438
  } if (rf & 2) {
428
439
  const model_r14 = i0.ɵɵnextContext(3).$implicit;
429
440
  const ctx_r1 = i0.ɵɵnextContext(5);
430
441
  i0.ɵɵconditional(ctx_r1.getVendorsForModelSync(model_r14.ModelID).length === 1 ? 0 : 1);
431
442
  } }
432
443
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Template(rf, ctx) { if (rf & 1) {
433
- i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_0_Template, 2, 5, "kendo-dropdownlist", 112)(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Template, 2, 1);
444
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_0_Template, 2, 5, "kendo-dropdownlist", 111)(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Conditional_1_Template, 2, 1);
434
445
  } if (rf & 2) {
435
446
  const model_r14 = i0.ɵɵnextContext(2).$implicit;
436
447
  const ctx_r1 = i0.ɵɵnextContext(5);
437
448
  i0.ɵɵconditional(ctx_r1.shouldShowVendorDropdown(model_r14.ModelID) ? 0 : 1);
438
449
  } }
439
450
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_1_Template(rf, ctx) { if (rf & 1) {
440
- i0.ɵɵelementStart(0, "span", 111);
451
+ i0.ɵɵelementStart(0, "span", 110);
441
452
  i0.ɵɵtext(1, "Select model first");
442
453
  i0.ɵɵelementEnd();
443
454
  } }
444
455
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Template(rf, ctx) { if (rf & 1) {
445
- i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Template, 2, 1)(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_1_Template, 2, 0, "span", 111);
456
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_0_Template, 2, 1)(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Conditional_1_Template, 2, 0, "span", 110);
446
457
  } if (rf & 2) {
447
458
  const model_r14 = i0.ɵɵnextContext().$implicit;
448
459
  i0.ɵɵconditional(model_r14.ModelID ? 0 : 1);
449
460
  } }
450
461
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Conditional_0_Conditional_2_Template(rf, ctx) { if (rf & 1) {
451
- i0.ɵɵelementStart(0, "span", 115);
462
+ i0.ɵɵelementStart(0, "span", 114);
452
463
  i0.ɵɵtext(1);
453
464
  i0.ɵɵelementEnd();
454
465
  } if (rf & 2) {
@@ -458,9 +469,9 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
458
469
  i0.ɵɵtextInterpolate1("(", ctx_r1.getModelVendorStatus(model_r14.ModelID, model_r14.VendorID), ")");
459
470
  } }
460
471
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Conditional_0_Template(rf, ctx) { if (rf & 1) {
461
- i0.ɵɵelementStart(0, "span", 120);
472
+ i0.ɵɵelementStart(0, "span", 119);
462
473
  i0.ɵɵtext(1);
463
- i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Conditional_0_Conditional_2_Template, 2, 1, "span", 115);
474
+ i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Conditional_0_Conditional_2_Template, 2, 1, "span", 114);
464
475
  i0.ɵɵelementEnd();
465
476
  } if (rf & 2) {
466
477
  const model_r14 = i0.ɵɵnextContext(2).$implicit;
@@ -472,18 +483,18 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
472
483
  i0.ɵɵconditional(ctx_r1.getModelVendorStatus(model_r14.ModelID, model_r14.VendorID) !== "Active" ? 2 : -1);
473
484
  } }
474
485
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Conditional_1_Template(rf, ctx) { if (rf & 1) {
475
- i0.ɵɵelementStart(0, "span", 119);
486
+ i0.ɵɵelementStart(0, "span", 118);
476
487
  i0.ɵɵtext(1, "-");
477
488
  i0.ɵɵelementEnd();
478
489
  } }
479
490
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Template(rf, ctx) { if (rf & 1) {
480
- i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Conditional_0_Template, 3, 4, "span", 118)(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Conditional_1_Template, 2, 0, "span", 119);
491
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Conditional_0_Template, 3, 4, "span", 117)(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Conditional_1_Template, 2, 0, "span", 118);
481
492
  } if (rf & 2) {
482
493
  const model_r14 = i0.ɵɵnextContext().$implicit;
483
494
  i0.ɵɵconditional(model_r14.VendorID && model_r14.ModelID ? 0 : 1);
484
495
  } }
485
496
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_11_Template(rf, ctx) { if (rf & 1) {
486
- i0.ɵɵelementStart(0, "span", 102);
497
+ i0.ɵɵelementStart(0, "span", 101);
487
498
  i0.ɵɵtext(1);
488
499
  i0.ɵɵpipe(2, "date");
489
500
  i0.ɵɵelementEnd();
@@ -493,23 +504,23 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
493
504
  i0.ɵɵtextInterpolate(i0.ɵɵpipeBind2(2, 1, model_r14.__mj_CreatedAt, "short"));
494
505
  } }
495
506
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_12_Template(rf, ctx) { if (rf & 1) {
496
- i0.ɵɵelementStart(0, "span", 103);
507
+ i0.ɵɵelementStart(0, "span", 102);
497
508
  i0.ɵɵtext(1, "New");
498
509
  i0.ɵɵelementEnd();
499
510
  } }
500
511
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_14_Template(rf, ctx) { if (rf & 1) {
501
512
  const _r18 = i0.ɵɵgetCurrentView();
502
- i0.ɵɵelementStart(0, "div", 121)(1, "kendo-button", 122);
503
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_14_Template_kendo_button_click_1_listener() { i0.ɵɵrestoreView(_r18); const ɵ$index_279_r12 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.moveModelUp(ɵ$index_279_r12)); });
504
- i0.ɵɵelement(2, "i", 123);
513
+ i0.ɵɵelementStart(0, "div", 120)(1, "button", 121);
514
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_14_Template_button_click_1_listener() { i0.ɵɵrestoreView(_r18); const ɵ$index_279_r12 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.moveModelUp(ɵ$index_279_r12)); });
515
+ i0.ɵɵelement(2, "i", 122);
505
516
  i0.ɵɵelementEnd();
506
- i0.ɵɵelementStart(3, "kendo-button", 124);
507
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_14_Template_kendo_button_click_3_listener() { i0.ɵɵrestoreView(_r18); const ɵ$index_279_r12 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.moveModelDown(ɵ$index_279_r12)); });
508
- i0.ɵɵelement(4, "i", 125);
517
+ i0.ɵɵelementStart(3, "button", 123);
518
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_14_Template_button_click_3_listener() { i0.ɵɵrestoreView(_r18); const ɵ$index_279_r12 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.moveModelDown(ɵ$index_279_r12)); });
519
+ i0.ɵɵelement(4, "i", 124);
509
520
  i0.ɵɵelementEnd()();
510
- i0.ɵɵelementStart(5, "kendo-button", 126);
511
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_14_Template_kendo_button_click_5_listener() { i0.ɵɵrestoreView(_r18); const ɵ$index_279_r12 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.removePromptModel(ɵ$index_279_r12)); });
512
- i0.ɵɵelement(6, "i", 127);
521
+ i0.ɵɵelementStart(5, "button", 125);
522
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_14_Template_button_click_5_listener() { i0.ɵɵrestoreView(_r18); const ɵ$index_279_r12 = i0.ɵɵnextContext().$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.removePromptModel(ɵ$index_279_r12)); });
523
+ i0.ɵɵelement(6, "i", 126);
513
524
  i0.ɵɵelementEnd();
514
525
  } if (rf & 2) {
515
526
  const ɵ$index_279_r12 = i0.ɵɵnextContext().$index;
@@ -543,10 +554,10 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
543
554
  } }
544
555
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_4_Conditional_5_Template(rf, ctx) { if (rf & 1) {
545
556
  const _r20 = i0.ɵɵgetCurrentView();
546
- i0.ɵɵelementStart(0, "div")(1, "label", 132);
557
+ i0.ɵɵelementStart(0, "div")(1, "label", 131);
547
558
  i0.ɵɵtext(2, "Parallel Count");
548
559
  i0.ɵɵelementEnd();
549
- i0.ɵɵelementStart(3, "kendo-numerictextbox", 134);
560
+ i0.ɵɵelementStart(3, "kendo-numerictextbox", 133);
550
561
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_4_Conditional_5_Template_kendo_numerictextbox_ngModelChange_3_listener($event) { i0.ɵɵrestoreView(_r20); const model_r14 = i0.ɵɵnextContext(3).$implicit; i0.ɵɵtwoWayBindingSet(model_r14.ParallelCount, $event) || (model_r14.ParallelCount = $event); return i0.ɵɵresetView($event); });
551
562
  i0.ɵɵelementEnd()();
552
563
  } if (rf & 2) {
@@ -559,10 +570,10 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
559
570
  } }
560
571
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_4_Conditional_6_Template(rf, ctx) { if (rf & 1) {
561
572
  const _r21 = i0.ɵɵgetCurrentView();
562
- i0.ɵɵelementStart(0, "div")(1, "label", 132);
573
+ i0.ɵɵelementStart(0, "div")(1, "label", 131);
563
574
  i0.ɵɵtext(2, "Config Parameter");
564
575
  i0.ɵɵelementEnd();
565
- i0.ɵɵelementStart(3, "kendo-textbox", 135);
576
+ i0.ɵɵelementStart(3, "kendo-textbox", 134);
566
577
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_4_Conditional_6_Template_kendo_textbox_ngModelChange_3_listener($event) { i0.ɵɵrestoreView(_r21); const model_r14 = i0.ɵɵnextContext(3).$implicit; i0.ɵɵtwoWayBindingSet(model_r14.ParallelConfigParam, $event) || (model_r14.ParallelConfigParam = $event); return i0.ɵɵresetView($event); });
567
578
  i0.ɵɵelementEnd()();
568
579
  } if (rf & 2) {
@@ -575,10 +586,10 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
575
586
  } }
576
587
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_4_Template(rf, ctx) { if (rf & 1) {
577
588
  const _r19 = i0.ɵɵgetCurrentView();
578
- i0.ɵɵelementStart(0, "div", 130)(1, "div")(2, "label", 132);
589
+ i0.ɵɵelementStart(0, "div", 129)(1, "div")(2, "label", 131);
579
590
  i0.ɵɵtext(3, "Parallel Mode");
580
591
  i0.ɵɵelementEnd();
581
- i0.ɵɵelementStart(4, "kendo-dropdownlist", 133);
592
+ i0.ɵɵelementStart(4, "kendo-dropdownlist", 132);
582
593
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_4_Template_kendo_dropdownlist_ngModelChange_4_listener($event) { i0.ɵɵrestoreView(_r19); const model_r14 = i0.ɵɵnextContext(2).$implicit; i0.ɵɵtwoWayBindingSet(model_r14.ParallelizationMode, $event) || (model_r14.ParallelizationMode = $event); return i0.ɵɵresetView($event); });
583
594
  i0.ɵɵelementEnd()();
584
595
  i0.ɵɵtemplate(5, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_4_Conditional_5_Template, 4, 5, "div")(6, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_4_Conditional_6_Template, 4, 2, "div");
@@ -629,7 +640,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
629
640
  i0.ɵɵtextInterpolate1(" ", model_r14.ParallelConfigParam, "");
630
641
  } }
631
642
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_5_Template(rf, ctx) { if (rf & 1) {
632
- i0.ɵɵelementStart(0, "div", 131);
643
+ i0.ɵɵelementStart(0, "div", 130);
633
644
  i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_5_Conditional_1_Template, 4, 1, "span")(2, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_5_Conditional_2_Template, 4, 1, "span")(3, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_5_Conditional_3_Template, 4, 1, "span");
634
645
  i0.ɵɵelementEnd();
635
646
  } if (rf & 2) {
@@ -642,11 +653,11 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
642
653
  i0.ɵɵconditional(model_r14.ParallelConfigParam ? 3 : -1);
643
654
  } }
644
655
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Template(rf, ctx) { if (rf & 1) {
645
- i0.ɵɵelementStart(0, "div", 107)(1, "div", 128);
646
- i0.ɵɵelement(2, "i", 129);
656
+ i0.ɵɵelementStart(0, "div", 106)(1, "div", 127);
657
+ i0.ɵɵelement(2, "i", 128);
647
658
  i0.ɵɵtext(3, " Model-Specific Parallel Execution ");
648
659
  i0.ɵɵelementEnd();
649
- i0.ɵɵtemplate(4, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_4_Template, 7, 13, "div", 130)(5, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_5_Template, 4, 3, "div", 131);
660
+ i0.ɵɵtemplate(4, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_4_Template, 7, 13, "div", 129)(5, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Conditional_5_Template, 4, 3, "div", 130);
650
661
  i0.ɵɵelementEnd();
651
662
  } if (rf & 2) {
652
663
  const ctx_r1 = i0.ɵɵnextContext(6);
@@ -655,29 +666,29 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
655
666
  } }
656
667
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Template(rf, ctx) { if (rf & 1) {
657
668
  const _r11 = i0.ɵɵgetCurrentView();
658
- i0.ɵɵelementStart(0, "div", 95);
669
+ i0.ɵɵelementStart(0, "div", 94);
659
670
  i0.ɵɵlistener("dragstart", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Template_div_dragstart_0_listener($event) { const ɵ$index_279_r12 = i0.ɵɵrestoreView(_r11).$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.onDragStart($event, ɵ$index_279_r12)); })("dragover", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Template_div_dragover_0_listener($event) { i0.ɵɵrestoreView(_r11); const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.onDragOver($event)); })("drop", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Template_div_drop_0_listener($event) { const ɵ$index_279_r12 = i0.ɵɵrestoreView(_r11).$index; const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.onDrop($event, ɵ$index_279_r12)); })("dragend", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Template_div_dragend_0_listener($event) { i0.ɵɵrestoreView(_r11); const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.onDragEnd($event)); });
660
- i0.ɵɵelementStart(1, "div", 96);
661
- i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_2_Template, 3, 1)(3, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_3_Template, 2, 3, "span", 97);
671
+ i0.ɵɵelementStart(1, "div", 95);
672
+ i0.ɵɵtemplate(2, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_2_Template, 3, 1)(3, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_3_Template, 2, 3, "span", 96);
662
673
  i0.ɵɵelementEnd();
663
- i0.ɵɵelementStart(4, "div", 98);
664
- i0.ɵɵtemplate(5, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_5_Template, 1, 5, "kendo-dropdownlist", 99)(6, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_6_Template, 2, 1, "span", 24);
674
+ i0.ɵɵelementStart(4, "div", 97);
675
+ i0.ɵɵtemplate(5, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_5_Template, 1, 5, "kendo-dropdownlist", 98)(6, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_6_Template, 2, 1, "span", 23);
665
676
  i0.ɵɵelementEnd();
666
- i0.ɵɵelementStart(7, "div", 100);
677
+ i0.ɵɵelementStart(7, "div", 99);
667
678
  i0.ɵɵtemplate(8, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_8_Template, 2, 1)(9, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_9_Template, 2, 1);
668
679
  i0.ɵɵelementEnd();
669
- i0.ɵɵelementStart(10, "div", 101);
670
- i0.ɵɵtemplate(11, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_11_Template, 3, 4, "span", 102)(12, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_12_Template, 2, 0, "span", 103);
680
+ i0.ɵɵelementStart(10, "div", 100);
681
+ i0.ɵɵtemplate(11, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_11_Template, 3, 4, "span", 101)(12, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_12_Template, 2, 0, "span", 102);
671
682
  i0.ɵɵelementEnd();
672
- i0.ɵɵelementStart(13, "div", 104);
683
+ i0.ɵɵelementStart(13, "div", 103);
673
684
  i0.ɵɵtemplate(14, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_14_Template, 7, 2);
674
685
  i0.ɵɵelementEnd()();
675
- i0.ɵɵelementStart(15, "div", 105);
686
+ i0.ɵɵelementStart(15, "div", 104);
676
687
  i0.ɵɵelement(16, "div");
677
- i0.ɵɵelementStart(17, "div")(18, "div", 106);
688
+ i0.ɵɵelementStart(17, "div")(18, "div", 105);
678
689
  i0.ɵɵtemplate(19, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_19_Template, 4, 1, "span")(20, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_20_Template, 4, 1, "span");
679
690
  i0.ɵɵelementEnd();
680
- i0.ɵɵtemplate(21, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Template, 6, 1, "div", 107);
691
+ i0.ɵɵtemplate(21, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Conditional_21_Template, 6, 1, "div", 106);
681
692
  i0.ɵɵelementEnd()();
682
693
  } if (rf & 2) {
683
694
  const model_r14 = ctx.$implicit;
@@ -704,20 +715,20 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
704
715
  } }
705
716
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Conditional_16_Template(rf, ctx) { if (rf & 1) {
706
717
  const _r22 = i0.ɵɵgetCurrentView();
707
- i0.ɵɵelementStart(0, "div", 93)(1, "kendo-button", 136);
708
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Conditional_16_Template_kendo_button_click_1_listener() { i0.ɵɵrestoreView(_r22); const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.addNewModel()); });
709
- i0.ɵɵelement(2, "i", 71);
718
+ i0.ɵɵelementStart(0, "div", 92)(1, "button", 135);
719
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Conditional_16_Template_button_click_1_listener() { i0.ɵɵrestoreView(_r22); const ctx_r1 = i0.ɵɵnextContext(5); return i0.ɵɵresetView(ctx_r1.addNewModel()); });
720
+ i0.ɵɵelement(2, "i", 70);
710
721
  i0.ɵɵtext(3, " Add Model ");
711
722
  i0.ɵɵelementEnd()();
712
723
  } }
713
724
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Template(rf, ctx) { if (rf & 1) {
714
- i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Conditional_0_Template, 3, 0, "div", 89);
715
- i0.ɵɵelementStart(1, "div", 90)(2, "div", 91);
716
- i0.ɵɵelement(3, "i", 92);
725
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Conditional_0_Template, 3, 0, "div", 88);
726
+ i0.ɵɵelementStart(1, "div", 89)(2, "div", 90);
727
+ i0.ɵɵelement(3, "i", 91);
717
728
  i0.ɵɵelementEnd();
718
729
  i0.ɵɵelementStart(4, "div");
719
730
  i0.ɵɵtext(5, "AI Model ");
720
- i0.ɵɵelementStart(6, "span", 52);
731
+ i0.ɵɵelementStart(6, "span", 51);
721
732
  i0.ɵɵtext(7, "*");
722
733
  i0.ɵɵelementEnd()();
723
734
  i0.ɵɵelementStart(8, "div");
@@ -730,7 +741,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
730
741
  i0.ɵɵtext(13, "Actions");
731
742
  i0.ɵɵelementEnd()();
732
743
  i0.ɵɵrepeaterCreate(14, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_For_15_Template, 22, 15, null, null, _forTrack0);
733
- i0.ɵɵtemplate(16, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Conditional_16_Template, 4, 0, "div", 93);
744
+ i0.ɵɵtemplate(16, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Conditional_16_Template, 4, 0, "div", 92);
734
745
  } if (rf & 2) {
735
746
  const ctx_r1 = i0.ɵɵnextContext(4);
736
747
  i0.ɵɵconditional(ctx_r1.promptModels.length > 1 ? 0 : -1);
@@ -740,16 +751,16 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Condi
740
751
  i0.ɵɵconditional(ctx_r1.EditMode ? 16 : -1);
741
752
  } }
742
753
  function AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Template(rf, ctx) { if (rf & 1) {
743
- i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_0_Template, 4, 1, "div", 85)(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Template, 17, 2);
754
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_0_Template, 4, 1, "div", 84)(1, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Conditional_1_Template, 17, 2);
744
755
  } if (rf & 2) {
745
756
  const ctx_r1 = i0.ɵɵnextContext(3);
746
757
  i0.ɵɵconditional(ctx_r1.promptModels.length === 0 ? 0 : 1);
747
758
  } }
748
759
  function AIPromptFormComponentExtended_form_1_Conditional_41_Template(rf, ctx) { if (rf & 1) {
749
- i0.ɵɵelementStart(0, "kendo-expansionpanel", 30);
750
- i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_41_ng_template_1_Template, 7, 1, "ng-template", 31);
751
- i0.ɵɵelementStart(2, "div", 37)(3, "div", 79);
752
- i0.ɵɵtemplate(4, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_4_Template, 3, 0, "div", 80)(5, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Template, 2, 1);
760
+ i0.ɵɵelementStart(0, "kendo-expansionpanel", 29);
761
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_41_ng_template_1_Template, 7, 1, "ng-template", 30);
762
+ i0.ɵɵelementStart(2, "div", 36)(3, "div", 78);
763
+ i0.ɵɵtemplate(4, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_4_Template, 3, 0, "div", 79)(5, AIPromptFormComponentExtended_form_1_Conditional_41_Conditional_5_Template, 2, 1);
753
764
  i0.ɵɵelementEnd()()();
754
765
  } if (rf & 2) {
755
766
  const ctx_r1 = i0.ɵɵnextContext(2);
@@ -758,32 +769,32 @@ function AIPromptFormComponentExtended_form_1_Conditional_41_Template(rf, ctx) {
758
769
  i0.ɵɵconditional(ctx_r1.isLoadingModels ? 4 : 5);
759
770
  } }
760
771
  function AIPromptFormComponentExtended_form_1_ng_template_43_Template(rf, ctx) { if (rf & 1) {
761
- i0.ɵɵelementStart(0, "span", 63);
762
- i0.ɵɵelement(1, "i", 137);
772
+ i0.ɵɵelementStart(0, "span", 62);
773
+ i0.ɵɵelement(1, "i", 136);
763
774
  i0.ɵɵtext(2, " Advanced Configuration ");
764
775
  i0.ɵɵelementEnd();
765
776
  } }
766
777
  function AIPromptFormComponentExtended_form_1_Conditional_48_Template(rf, ctx) { if (rf & 1) {
767
- i0.ɵɵelement(0, "mj-form-field", 40);
778
+ i0.ɵɵelement(0, "mj-form-field", 39);
768
779
  } if (rf & 2) {
769
780
  const ctx_r1 = i0.ɵɵnextContext(2);
770
781
  i0.ɵɵproperty("record", ctx_r1.record)("ShowLabel", true)("EditMode", ctx_r1.EditMode);
771
782
  } }
772
783
  function AIPromptFormComponentExtended_form_1_Conditional_49_Template(rf, ctx) { if (rf & 1) {
773
- i0.ɵɵelement(0, "mj-form-field", 41);
784
+ i0.ɵɵelement(0, "mj-form-field", 40);
774
785
  } if (rf & 2) {
775
786
  const ctx_r1 = i0.ɵɵnextContext(2);
776
787
  i0.ɵɵproperty("record", ctx_r1.record)("ShowLabel", true)("EditMode", ctx_r1.EditMode);
777
788
  } }
778
789
  function AIPromptFormComponentExtended_form_1_Conditional_57_Conditional_0_Template(rf, ctx) { if (rf & 1) {
779
- i0.ɵɵelementStart(0, "div", 138);
780
- i0.ɵɵelement(1, "i", 55);
790
+ i0.ɵɵelementStart(0, "div", 137);
791
+ i0.ɵɵelement(1, "i", 54);
781
792
  i0.ɵɵtext(2, " Loading prompts... ");
782
793
  i0.ɵɵelementEnd();
783
794
  } }
784
795
  function AIPromptFormComponentExtended_form_1_Conditional_57_Conditional_1_Template(rf, ctx) { if (rf & 1) {
785
796
  const _r23 = i0.ɵɵgetCurrentView();
786
- i0.ɵɵelementStart(0, "kendo-dropdowntree", 140);
797
+ i0.ɵɵelementStart(0, "kendo-dropdowntree", 139);
787
798
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_57_Conditional_1_Template_kendo_dropdowntree_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r23); const ctx_r1 = i0.ɵɵnextContext(3); i0.ɵɵtwoWayBindingSet(ctx_r1.record.ResultSelectorPromptID, $event) || (ctx_r1.record.ResultSelectorPromptID = $event); return i0.ɵɵresetView($event); });
788
799
  i0.ɵɵlistener("valueChange", function AIPromptFormComponentExtended_form_1_Conditional_57_Conditional_1_Template_kendo_dropdowntree_valueChange_0_listener($event) { i0.ɵɵrestoreView(_r23); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.onResultSelectorChange($event)); });
789
800
  i0.ɵɵelementEnd();
@@ -793,13 +804,13 @@ function AIPromptFormComponentExtended_form_1_Conditional_57_Conditional_1_Templ
793
804
  i0.ɵɵproperty("data", ctx_r1.resultSelectorTreeData)("valuePrimitive", true)("filterable", true);
794
805
  } }
795
806
  function AIPromptFormComponentExtended_form_1_Conditional_57_Template(rf, ctx) { if (rf & 1) {
796
- i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_57_Conditional_0_Template, 3, 0, "div", 138)(1, AIPromptFormComponentExtended_form_1_Conditional_57_Conditional_1_Template, 1, 4, "kendo-dropdowntree", 139);
807
+ i0.ɵɵtemplate(0, AIPromptFormComponentExtended_form_1_Conditional_57_Conditional_0_Template, 3, 0, "div", 137)(1, AIPromptFormComponentExtended_form_1_Conditional_57_Conditional_1_Template, 1, 4, "kendo-dropdowntree", 138);
797
808
  } if (rf & 2) {
798
809
  const ctx_r1 = i0.ɵɵnextContext(2);
799
810
  i0.ɵɵconditional(ctx_r1.isLoadingResultSelectorData ? 0 : 1);
800
811
  } }
801
812
  function AIPromptFormComponentExtended_form_1_Conditional_58_Template(rf, ctx) { if (rf & 1) {
802
- i0.ɵɵelementStart(0, "span", 47);
813
+ i0.ɵɵelementStart(0, "span", 46);
803
814
  i0.ɵɵtext(1);
804
815
  i0.ɵɵelementEnd();
805
816
  } if (rf & 2) {
@@ -808,20 +819,20 @@ function AIPromptFormComponentExtended_form_1_Conditional_58_Template(rf, ctx) {
808
819
  i0.ɵɵtextInterpolate(ctx_r1.getPromptDisplayName(ctx_r1.record.ResultSelectorPromptID || "") || "None selected");
809
820
  } }
810
821
  function AIPromptFormComponentExtended_form_1_Conditional_59_ng_template_1_Template(rf, ctx) { if (rf & 1) {
811
- i0.ɵɵelementStart(0, "span", 63);
812
- i0.ɵɵelement(1, "i", 23);
822
+ i0.ɵɵelementStart(0, "span", 62);
823
+ i0.ɵɵelement(1, "i", 22);
813
824
  i0.ɵɵtext(2, " Output Example (JSON) ");
814
- i0.ɵɵelementStart(3, "span", 144);
825
+ i0.ɵɵelementStart(3, "span", 143);
815
826
  i0.ɵɵtext(4, "\u2022 Required for object output type");
816
827
  i0.ɵɵelementEnd()();
817
828
  } }
818
829
  function AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_3_Template(rf, ctx) { if (rf & 1) {
819
830
  const _r24 = i0.ɵɵgetCurrentView();
820
- i0.ɵɵelementStart(0, "mj-code-editor", 145);
831
+ i0.ɵɵelementStart(0, "mj-code-editor", 144);
821
832
  i0.ɵɵtwoWayListener("ngModelChange", function AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_3_Template_mj_code_editor_ngModelChange_0_listener($event) { i0.ɵɵrestoreView(_r24); const ctx_r1 = i0.ɵɵnextContext(3); i0.ɵɵtwoWayBindingSet(ctx_r1.record.OutputExample, $event) || (ctx_r1.record.OutputExample = $event); return i0.ɵɵresetView($event); });
822
833
  i0.ɵɵelementEnd();
823
- i0.ɵɵelementStart(1, "div", 146);
824
- i0.ɵɵelement(2, "i", 86);
834
+ i0.ɵɵelementStart(1, "div", 145);
835
+ i0.ɵɵelement(2, "i", 85);
825
836
  i0.ɵɵtext(3, " Provide a JSON example that defines the expected structure for object output validation. ");
826
837
  i0.ɵɵelementEnd();
827
838
  } if (rf & 2) {
@@ -829,7 +840,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_3_Templ
829
840
  i0.ɵɵtwoWayProperty("ngModel", ctx_r1.record.OutputExample);
830
841
  } }
831
842
  function AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_4_Template(rf, ctx) { if (rf & 1) {
832
- i0.ɵɵelementStart(0, "div", 142);
843
+ i0.ɵɵelementStart(0, "div", 141);
833
844
  i0.ɵɵtext(1);
834
845
  i0.ɵɵelementEnd();
835
846
  } if (rf & 2) {
@@ -838,16 +849,16 @@ function AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_4_Templ
838
849
  i0.ɵɵtextInterpolate(ctx_r1.record.OutputExample);
839
850
  } }
840
851
  function AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_5_Template(rf, ctx) { if (rf & 1) {
841
- i0.ɵɵelementStart(0, "div", 143);
842
- i0.ɵɵelement(1, "i", 147);
852
+ i0.ɵɵelementStart(0, "div", 142);
853
+ i0.ɵɵelement(1, "i", 146);
843
854
  i0.ɵɵtext(2, " Output example is required when output type is 'object' ");
844
855
  i0.ɵɵelementEnd();
845
856
  } }
846
857
  function AIPromptFormComponentExtended_form_1_Conditional_59_Template(rf, ctx) { if (rf & 1) {
847
- i0.ɵɵelementStart(0, "kendo-expansionpanel", 30);
848
- i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_59_ng_template_1_Template, 5, 0, "ng-template", 31);
849
- i0.ɵɵelementStart(2, "div", 141);
850
- i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_3_Template, 4, 1)(4, AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_4_Template, 2, 1, "div", 142)(5, AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_5_Template, 3, 0, "div", 143);
858
+ i0.ɵɵelementStart(0, "kendo-expansionpanel", 29);
859
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_59_ng_template_1_Template, 5, 0, "ng-template", 30);
860
+ i0.ɵɵelementStart(2, "div", 140);
861
+ i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_3_Template, 4, 1)(4, AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_4_Template, 2, 1, "div", 141)(5, AIPromptFormComponentExtended_form_1_Conditional_59_Conditional_5_Template, 3, 0, "div", 142);
851
862
  i0.ɵɵelementEnd()();
852
863
  } if (rf & 2) {
853
864
  const ctx_r1 = i0.ɵɵnextContext(2);
@@ -856,7 +867,7 @@ function AIPromptFormComponentExtended_form_1_Conditional_59_Template(rf, ctx) {
856
867
  i0.ɵɵconditional(ctx_r1.EditMode ? 3 : ctx_r1.record.OutputExample ? 4 : 5);
857
868
  } }
858
869
  function AIPromptFormComponentExtended_form_1_Conditional_60_ng_template_1_Conditional_3_Template(rf, ctx) { if (rf & 1) {
859
- i0.ɵɵelementStart(0, "span", 150);
870
+ i0.ɵɵelementStart(0, "span", 149);
860
871
  i0.ɵɵtext(1);
861
872
  i0.ɵɵelementEnd();
862
873
  } if (rf & 2) {
@@ -865,10 +876,10 @@ function AIPromptFormComponentExtended_form_1_Conditional_60_ng_template_1_Condi
865
876
  i0.ɵɵtextInterpolate1("(", ctx_r1.executionHistory.length, ")");
866
877
  } }
867
878
  function AIPromptFormComponentExtended_form_1_Conditional_60_ng_template_1_Template(rf, ctx) { if (rf & 1) {
868
- i0.ɵɵelementStart(0, "span", 63);
869
- i0.ɵɵelement(1, "i", 149);
879
+ i0.ɵɵelementStart(0, "span", 62);
880
+ i0.ɵɵelement(1, "i", 148);
870
881
  i0.ɵɵtext(2, " Execution History ");
871
- i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_60_ng_template_1_Conditional_3_Template, 2, 1, "span", 150);
882
+ i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_60_ng_template_1_Conditional_3_Template, 2, 1, "span", 149);
872
883
  i0.ɵɵelementEnd();
873
884
  } if (rf & 2) {
874
885
  const ctx_r1 = i0.ɵɵnextContext(3);
@@ -876,48 +887,48 @@ function AIPromptFormComponentExtended_form_1_Conditional_60_ng_template_1_Templ
876
887
  i0.ɵɵconditional(ctx_r1.executionHistory.length > 0 ? 3 : -1);
877
888
  } }
878
889
  function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_3_Template(rf, ctx) { if (rf & 1) {
879
- i0.ɵɵelementStart(0, "div", 148);
880
- i0.ɵɵelement(1, "i", 151);
890
+ i0.ɵɵelementStart(0, "div", 147);
891
+ i0.ɵɵelement(1, "i", 150);
881
892
  i0.ɵɵelementStart(2, "p");
882
893
  i0.ɵɵtext(3, "Loading execution history...");
883
894
  i0.ɵɵelementEnd()();
884
895
  } }
885
896
  function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_4_Template(rf, ctx) { if (rf & 1) {
886
- i0.ɵɵelementStart(0, "div", 148);
887
- i0.ɵɵelement(1, "i", 152);
897
+ i0.ɵɵelementStart(0, "div", 147);
898
+ i0.ɵɵelement(1, "i", 151);
888
899
  i0.ɵɵelementStart(2, "p");
889
900
  i0.ɵɵtext(3, "No execution history yet");
890
901
  i0.ɵɵelementEnd();
891
- i0.ɵɵelementStart(4, "p", 120);
902
+ i0.ɵɵelementStart(4, "p", 119);
892
903
  i0.ɵɵtext(5, "Run this prompt to see execution history here");
893
904
  i0.ɵɵelementEnd()();
894
905
  } }
895
906
  function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_9_Template(rf, ctx) { if (rf & 1) {
896
- i0.ɵɵelement(0, "i", 166);
907
+ i0.ɵɵelement(0, "i", 165);
897
908
  } if (rf & 2) {
898
909
  const ctx_r1 = i0.ɵɵnextContext(4);
899
910
  i0.ɵɵclassMap("fa-solid fa-sort-" + (ctx_r1.historySortDirection === "asc" ? "up" : "down"));
900
911
  } }
901
912
  function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_12_Template(rf, ctx) { if (rf & 1) {
902
- i0.ɵɵelement(0, "i", 166);
913
+ i0.ɵɵelement(0, "i", 165);
903
914
  } if (rf & 2) {
904
915
  const ctx_r1 = i0.ɵɵnextContext(4);
905
916
  i0.ɵɵclassMap("fa-solid fa-sort-" + (ctx_r1.historySortDirection === "asc" ? "up" : "down"));
906
917
  } }
907
918
  function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_15_Template(rf, ctx) { if (rf & 1) {
908
- i0.ɵɵelement(0, "i", 166);
919
+ i0.ɵɵelement(0, "i", 165);
909
920
  } if (rf & 2) {
910
921
  const ctx_r1 = i0.ɵɵnextContext(4);
911
922
  i0.ɵɵclassMap("fa-solid fa-sort-" + (ctx_r1.historySortDirection === "asc" ? "up" : "down"));
912
923
  } }
913
924
  function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_18_Template(rf, ctx) { if (rf & 1) {
914
- i0.ɵɵelement(0, "i", 166);
925
+ i0.ɵɵelement(0, "i", 165);
915
926
  } if (rf & 2) {
916
927
  const ctx_r1 = i0.ɵɵnextContext(4);
917
928
  i0.ɵɵclassMap("fa-solid fa-sort-" + (ctx_r1.historySortDirection === "asc" ? "up" : "down"));
918
929
  } }
919
930
  function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_For_41_Conditional_20_Template(rf, ctx) { if (rf & 1) {
920
- i0.ɵɵelementStart(0, "span", 173);
931
+ i0.ɵɵelementStart(0, "span", 172);
921
932
  i0.ɵɵtext(1);
922
933
  i0.ɵɵelementEnd();
923
934
  } if (rf & 2) {
@@ -927,34 +938,34 @@ function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_For_4
927
938
  } }
928
939
  function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_For_41_Template(rf, ctx) { if (rf & 1) {
929
940
  const _r26 = i0.ɵɵgetCurrentView();
930
- i0.ɵɵelementStart(0, "tr", 167)(1, "td", 168)(2, "span", 169);
941
+ i0.ɵɵelementStart(0, "tr", 166)(1, "td", 167)(2, "span", 168);
931
942
  i0.ɵɵelement(3, "i");
932
- i0.ɵɵelementStart(4, "span", 24);
943
+ i0.ɵɵelementStart(4, "span", 23);
933
944
  i0.ɵɵtext(5);
934
945
  i0.ɵɵelementEnd()()();
935
- i0.ɵɵelementStart(6, "td", 170);
946
+ i0.ɵɵelementStart(6, "td", 169);
936
947
  i0.ɵɵtext(7);
937
948
  i0.ɵɵpipe(8, "date");
938
949
  i0.ɵɵelementEnd();
939
- i0.ɵɵelementStart(9, "td", 170)(10, "span", 169);
940
- i0.ɵɵelement(11, "i", 81);
950
+ i0.ɵɵelementStart(9, "td", 169)(10, "span", 168);
951
+ i0.ɵɵelement(11, "i", 80);
941
952
  i0.ɵɵtext(12);
942
953
  i0.ɵɵelementEnd()();
943
- i0.ɵɵelementStart(13, "td", 170);
954
+ i0.ɵɵelementStart(13, "td", 169);
944
955
  i0.ɵɵtext(14);
945
956
  i0.ɵɵelementEnd();
946
- i0.ɵɵelementStart(15, "td", 171);
957
+ i0.ɵɵelementStart(15, "td", 170);
947
958
  i0.ɵɵtext(16);
948
959
  i0.ɵɵelementEnd();
949
- i0.ɵɵelementStart(17, "td", 171);
960
+ i0.ɵɵelementStart(17, "td", 170);
950
961
  i0.ɵɵtext(18);
951
962
  i0.ɵɵelementEnd();
952
- i0.ɵɵelementStart(19, "td", 172);
953
- i0.ɵɵtemplate(20, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_For_41_Conditional_20_Template, 2, 1, "span", 173);
963
+ i0.ɵɵelementStart(19, "td", 171);
964
+ i0.ɵɵtemplate(20, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_For_41_Conditional_20_Template, 2, 1, "span", 172);
954
965
  i0.ɵɵelementEnd();
955
- i0.ɵɵelementStart(21, "td", 172)(22, "kendo-button", 174);
956
- i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_For_41_Template_kendo_button_click_22_listener() { const run_r27 = i0.ɵɵrestoreView(_r26).$implicit; const ctx_r1 = i0.ɵɵnextContext(4); return i0.ɵɵresetView(ctx_r1.navigateToPromptRun(run_r27.ID)); });
957
- i0.ɵɵelement(23, "i", 175);
966
+ i0.ɵɵelementStart(21, "td", 171)(22, "button", 173);
967
+ i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_For_41_Template_button_click_22_listener() { const run_r27 = i0.ɵɵrestoreView(_r26).$implicit; const ctx_r1 = i0.ɵɵnextContext(4); return i0.ɵɵresetView(ctx_r1.navigateToPromptRun(run_r27.ID)); });
968
+ i0.ɵɵelement(23, "i", 174);
958
969
  i0.ɵɵelementEnd()()();
959
970
  } if (rf & 2) {
960
971
  const run_r27 = ctx.$implicit;
@@ -983,58 +994,58 @@ function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_For_4
983
994
  } }
984
995
  function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Template(rf, ctx) { if (rf & 1) {
985
996
  const _r25 = i0.ɵɵgetCurrentView();
986
- i0.ɵɵelementStart(0, "div", 153)(1, "div", 119);
997
+ i0.ɵɵelementStart(0, "div", 152)(1, "div", 118);
987
998
  i0.ɵɵtext(2);
988
999
  i0.ɵɵelementEnd();
989
- i0.ɵɵelementStart(3, "div", 154)(4, "span", 155);
1000
+ i0.ɵɵelementStart(3, "div", 153)(4, "span", 154);
990
1001
  i0.ɵɵtext(5, "Sort by:");
991
1002
  i0.ɵɵelementEnd();
992
- i0.ɵɵelementStart(6, "kendo-buttongroup", 156)(7, "button", 157);
1003
+ i0.ɵɵelementStart(6, "kendo-buttongroup", 155)(7, "button", 156);
993
1004
  i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Template_button_click_7_listener() { i0.ɵɵrestoreView(_r25); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.changeHistorySort("runAt")); });
994
1005
  i0.ɵɵtext(8, " Date ");
995
- i0.ɵɵtemplate(9, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_9_Template, 1, 2, "i", 158);
1006
+ i0.ɵɵtemplate(9, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_9_Template, 1, 2, "i", 157);
996
1007
  i0.ɵɵelementEnd();
997
- i0.ɵɵelementStart(10, "button", 157);
1008
+ i0.ɵɵelementStart(10, "button", 156);
998
1009
  i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Template_button_click_10_listener() { i0.ɵɵrestoreView(_r25); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.changeHistorySort("executionTime")); });
999
1010
  i0.ɵɵtext(11, " Duration ");
1000
- i0.ɵɵtemplate(12, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_12_Template, 1, 2, "i", 158);
1011
+ i0.ɵɵtemplate(12, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_12_Template, 1, 2, "i", 157);
1001
1012
  i0.ɵɵelementEnd();
1002
- i0.ɵɵelementStart(13, "button", 157);
1013
+ i0.ɵɵelementStart(13, "button", 156);
1003
1014
  i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Template_button_click_13_listener() { i0.ɵɵrestoreView(_r25); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.changeHistorySort("tokens")); });
1004
1015
  i0.ɵɵtext(14, " Tokens ");
1005
- i0.ɵɵtemplate(15, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_15_Template, 1, 2, "i", 158);
1016
+ i0.ɵɵtemplate(15, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_15_Template, 1, 2, "i", 157);
1006
1017
  i0.ɵɵelementEnd();
1007
- i0.ɵɵelementStart(16, "button", 157);
1018
+ i0.ɵɵelementStart(16, "button", 156);
1008
1019
  i0.ɵɵlistener("click", function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Template_button_click_16_listener() { i0.ɵɵrestoreView(_r25); const ctx_r1 = i0.ɵɵnextContext(3); return i0.ɵɵresetView(ctx_r1.changeHistorySort("cost")); });
1009
1020
  i0.ɵɵtext(17, " Cost ");
1010
- i0.ɵɵtemplate(18, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_18_Template, 1, 2, "i", 158);
1021
+ i0.ɵɵtemplate(18, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Conditional_18_Template, 1, 2, "i", 157);
1011
1022
  i0.ɵɵelementEnd()()()();
1012
- i0.ɵɵelementStart(19, "div", 159)(20, "table", 160)(21, "thead")(22, "tr", 161)(23, "th", 162);
1023
+ i0.ɵɵelementStart(19, "div", 158)(20, "table", 159)(21, "thead")(22, "tr", 160)(23, "th", 161);
1013
1024
  i0.ɵɵtext(24, "Status");
1014
1025
  i0.ɵɵelementEnd();
1015
- i0.ɵɵelementStart(25, "th", 162);
1026
+ i0.ɵɵelementStart(25, "th", 161);
1016
1027
  i0.ɵɵtext(26, "Date & Time");
1017
1028
  i0.ɵɵelementEnd();
1018
- i0.ɵɵelementStart(27, "th", 162);
1029
+ i0.ɵɵelementStart(27, "th", 161);
1019
1030
  i0.ɵɵtext(28, "Model");
1020
1031
  i0.ɵɵelementEnd();
1021
- i0.ɵɵelementStart(29, "th", 162);
1032
+ i0.ɵɵelementStart(29, "th", 161);
1022
1033
  i0.ɵɵtext(30, "Duration");
1023
1034
  i0.ɵɵelementEnd();
1024
- i0.ɵɵelementStart(31, "th", 163);
1035
+ i0.ɵɵelementStart(31, "th", 162);
1025
1036
  i0.ɵɵtext(32, "Tokens");
1026
1037
  i0.ɵɵelementEnd();
1027
- i0.ɵɵelementStart(33, "th", 163);
1038
+ i0.ɵɵelementStart(33, "th", 162);
1028
1039
  i0.ɵɵtext(34, "Cost");
1029
1040
  i0.ɵɵelementEnd();
1030
- i0.ɵɵelementStart(35, "th", 164);
1041
+ i0.ɵɵelementStart(35, "th", 163);
1031
1042
  i0.ɵɵtext(36, "Type");
1032
1043
  i0.ɵɵelementEnd();
1033
- i0.ɵɵelementStart(37, "th", 164);
1044
+ i0.ɵɵelementStart(37, "th", 163);
1034
1045
  i0.ɵɵtext(38, "Actions");
1035
1046
  i0.ɵɵelementEnd()()();
1036
1047
  i0.ɵɵelementStart(39, "tbody");
1037
- i0.ɵɵrepeaterCreate(40, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_For_41_Template, 24, 18, "tr", 165, _forTrack1);
1048
+ i0.ɵɵrepeaterCreate(40, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_For_41_Template, 24, 18, "tr", 164, _forTrack1);
1038
1049
  i0.ɵɵelementEnd()()();
1039
1050
  } if (rf & 2) {
1040
1051
  const ctx_r1 = i0.ɵɵnextContext(3);
@@ -1060,10 +1071,10 @@ function AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Templ
1060
1071
  i0.ɵɵrepeater(ctx_r1.executionHistory);
1061
1072
  } }
1062
1073
  function AIPromptFormComponentExtended_form_1_Conditional_60_Template(rf, ctx) { if (rf & 1) {
1063
- i0.ɵɵelementStart(0, "kendo-expansionpanel", 30);
1064
- i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_60_ng_template_1_Template, 4, 1, "ng-template", 31);
1065
- i0.ɵɵelementStart(2, "div", 141);
1066
- i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_3_Template, 4, 0, "div", 148)(4, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_4_Template, 6, 0, "div", 148)(5, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Template, 42, 9);
1074
+ i0.ɵɵelementStart(0, "kendo-expansionpanel", 29);
1075
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_60_ng_template_1_Template, 4, 1, "ng-template", 30);
1076
+ i0.ɵɵelementStart(2, "div", 140);
1077
+ i0.ɵɵtemplate(3, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_3_Template, 4, 0, "div", 147)(4, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_4_Template, 6, 0, "div", 147)(5, AIPromptFormComponentExtended_form_1_Conditional_60_Conditional_5_Template, 42, 9);
1067
1078
  i0.ɵɵelementEnd()();
1068
1079
  } if (rf & 2) {
1069
1080
  const ctx_r1 = i0.ɵɵnextContext(2);
@@ -1072,16 +1083,16 @@ function AIPromptFormComponentExtended_form_1_Conditional_60_Template(rf, ctx) {
1072
1083
  i0.ɵɵconditional(ctx_r1.isLoadingHistory ? 3 : ctx_r1.executionHistory.length === 0 ? 4 : 5);
1073
1084
  } }
1074
1085
  function AIPromptFormComponentExtended_form_1_Conditional_61_ng_template_1_Template(rf, ctx) { if (rf & 1) {
1075
- i0.ɵɵelementStart(0, "span", 63);
1076
- i0.ɵɵelement(1, "i", 177);
1086
+ i0.ɵɵelementStart(0, "span", 62);
1087
+ i0.ɵɵelement(1, "i", 176);
1077
1088
  i0.ɵɵtext(2, " Result Cache ");
1078
1089
  i0.ɵɵelementEnd();
1079
1090
  } }
1080
1091
  function AIPromptFormComponentExtended_form_1_Conditional_61_Template(rf, ctx) { if (rf & 1) {
1081
- i0.ɵɵelementStart(0, "kendo-expansionpanel", 30);
1082
- i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_61_ng_template_1_Template, 3, 0, "ng-template", 31);
1083
- i0.ɵɵelementStart(2, "div", 37);
1084
- i0.ɵɵelement(3, "mj-user-view-grid", 176);
1092
+ i0.ɵɵelementStart(0, "kendo-expansionpanel", 29);
1093
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_61_ng_template_1_Template, 3, 0, "ng-template", 30);
1094
+ i0.ɵɵelementStart(2, "div", 36);
1095
+ i0.ɵɵelement(3, "mj-user-view-grid", 175);
1085
1096
  i0.ɵɵelementEnd()();
1086
1097
  } if (rf & 2) {
1087
1098
  const ctx_r1 = i0.ɵɵnextContext(2);
@@ -1090,23 +1101,23 @@ function AIPromptFormComponentExtended_form_1_Conditional_61_Template(rf, ctx) {
1090
1101
  i0.ɵɵproperty("Params", ctx_r1.BuildRelationshipViewParamsByEntityName("AI Result Cache", "AIPromptID"))("NewRecordValues", ctx_r1.NewRecordValues("AI Result Cache"))("AllowLoad", true)("EditMode", ctx_r1.GridEditMode())("BottomMargin", 0);
1091
1102
  } }
1092
1103
  function AIPromptFormComponentExtended_form_1_Conditional_62_ng_template_1_Template(rf, ctx) { if (rf & 1) {
1093
- i0.ɵɵelementStart(0, "span", 63);
1094
- i0.ɵɵelement(1, "i", 180);
1104
+ i0.ɵɵelementStart(0, "span", 62);
1105
+ i0.ɵɵelement(1, "i", 179);
1095
1106
  i0.ɵɵtext(2, " Related Items ");
1096
1107
  i0.ɵɵelementEnd();
1097
1108
  } }
1098
1109
  function AIPromptFormComponentExtended_form_1_Conditional_62_Template(rf, ctx) { if (rf & 1) {
1099
- i0.ɵɵelementStart(0, "kendo-expansionpanel", 30);
1100
- i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_62_ng_template_1_Template, 3, 0, "ng-template", 31);
1101
- i0.ɵɵelementStart(2, "div", 37)(3, "div", 38)(4, "div")(5, "h6", 178);
1110
+ i0.ɵɵelementStart(0, "kendo-expansionpanel", 29);
1111
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Conditional_62_ng_template_1_Template, 3, 0, "ng-template", 30);
1112
+ i0.ɵɵelementStart(2, "div", 36)(3, "div", 37)(4, "div")(5, "h6", 177);
1102
1113
  i0.ɵɵtext(6, "AI Agents Using This Prompt");
1103
1114
  i0.ɵɵelementEnd();
1104
- i0.ɵɵelement(7, "mj-user-view-grid", 179);
1115
+ i0.ɵɵelement(7, "mj-user-view-grid", 178);
1105
1116
  i0.ɵɵelementEnd();
1106
- i0.ɵɵelementStart(8, "div")(9, "h6", 178);
1117
+ i0.ɵɵelementStart(8, "div")(9, "h6", 177);
1107
1118
  i0.ɵɵtext(10, "Prompts Using This as Result Selector");
1108
1119
  i0.ɵɵelementEnd();
1109
- i0.ɵɵelement(11, "mj-user-view-grid", 179);
1120
+ i0.ɵɵelement(11, "mj-user-view-grid", 178);
1110
1121
  i0.ɵɵelementEnd()()()();
1111
1122
  } if (rf & 2) {
1112
1123
  const ctx_r1 = i0.ɵɵnextContext(2);
@@ -1117,59 +1128,59 @@ function AIPromptFormComponentExtended_form_1_Conditional_62_Template(rf, ctx) {
1117
1128
  i0.ɵɵproperty("Params", ctx_r1.BuildRelationshipViewParamsByEntityName("AI Prompts", "ResultSelectorPromptID"))("NewRecordValues", ctx_r1.NewRecordValues("AI Prompts"))("AllowLoad", true)("EditMode", ctx_r1.GridEditMode())("BottomMargin", 0);
1118
1129
  } }
1119
1130
  function AIPromptFormComponentExtended_form_1_Template(rf, ctx) { if (rf & 1) {
1120
- i0.ɵɵelementStart(0, "form", 6, 0);
1121
- i0.ɵɵelement(2, "mj-form-toolbar", 7);
1122
- i0.ɵɵelementStart(3, "div", 8)(4, "div", 9)(5, "div", 10)(6, "div", 11)(7, "div", 12);
1123
- i0.ɵɵelement(8, "i", 13);
1124
- i0.ɵɵtemplate(9, AIPromptFormComponentExtended_form_1_Conditional_9_Template, 1, 1, "kendo-textbox", 14)(10, AIPromptFormComponentExtended_form_1_Conditional_10_Template, 4, 4);
1125
- i0.ɵɵelementEnd();
1126
- i0.ɵɵtemplate(11, AIPromptFormComponentExtended_form_1_Conditional_11_Template, 12, 11, "div", 15)(12, AIPromptFormComponentExtended_form_1_Conditional_12_Template, 1, 2, "kendo-textarea", 16)(13, AIPromptFormComponentExtended_form_1_Conditional_13_Template, 2, 1, "p", 17);
1127
- i0.ɵɵelementStart(14, "div", 18);
1128
- i0.ɵɵtemplate(15, AIPromptFormComponentExtended_form_1_Conditional_15_Template, 6, 1, "div", 19);
1129
- i0.ɵɵelementStart(16, "div", 19);
1130
- i0.ɵɵelement(17, "i", 20);
1131
- i0.ɵɵelementStart(18, "span", 21);
1131
+ i0.ɵɵelementStart(0, "form", 5, 0);
1132
+ i0.ɵɵelement(2, "mj-form-toolbar", 6);
1133
+ i0.ɵɵelementStart(3, "div", 7)(4, "div", 8)(5, "div", 9)(6, "div", 10)(7, "div", 11);
1134
+ i0.ɵɵelement(8, "i", 12);
1135
+ i0.ɵɵtemplate(9, AIPromptFormComponentExtended_form_1_Conditional_9_Template, 1, 1, "kendo-textbox", 13)(10, AIPromptFormComponentExtended_form_1_Conditional_10_Template, 4, 4);
1136
+ i0.ɵɵelementEnd();
1137
+ i0.ɵɵtemplate(11, AIPromptFormComponentExtended_form_1_Conditional_11_Template, 12, 11, "div", 14)(12, AIPromptFormComponentExtended_form_1_Conditional_12_Template, 1, 2, "kendo-textarea", 15)(13, AIPromptFormComponentExtended_form_1_Conditional_13_Template, 2, 1, "p", 16);
1138
+ i0.ɵɵelementStart(14, "div", 17);
1139
+ i0.ɵɵtemplate(15, AIPromptFormComponentExtended_form_1_Conditional_15_Template, 6, 1, "div", 18);
1140
+ i0.ɵɵelementStart(16, "div", 18);
1141
+ i0.ɵɵelement(17, "i", 19);
1142
+ i0.ɵɵelementStart(18, "span", 20);
1132
1143
  i0.ɵɵtext(19, "Parallelization:");
1133
1144
  i0.ɵɵelementEnd();
1134
- i0.ɵɵelementStart(20, "span", 22);
1145
+ i0.ɵɵelementStart(20, "span", 21);
1135
1146
  i0.ɵɵtext(21);
1136
1147
  i0.ɵɵelementEnd()();
1137
- i0.ɵɵelementStart(22, "div", 19);
1138
- i0.ɵɵelement(23, "i", 23);
1139
- i0.ɵɵelementStart(24, "span", 21);
1148
+ i0.ɵɵelementStart(22, "div", 18);
1149
+ i0.ɵɵelement(23, "i", 22);
1150
+ i0.ɵɵelementStart(24, "span", 20);
1140
1151
  i0.ɵɵtext(25, "Output:");
1141
1152
  i0.ɵɵelementEnd();
1142
- i0.ɵɵelementStart(26, "span", 24);
1153
+ i0.ɵɵelementStart(26, "span", 23);
1143
1154
  i0.ɵɵtext(27);
1144
1155
  i0.ɵɵelementEnd()();
1145
- i0.ɵɵtemplate(28, AIPromptFormComponentExtended_form_1_Conditional_28_Template, 4, 0, "div", 19);
1156
+ i0.ɵɵtemplate(28, AIPromptFormComponentExtended_form_1_Conditional_28_Template, 4, 0, "div", 18);
1146
1157
  i0.ɵɵelementEnd()();
1147
- i0.ɵɵelementStart(29, "div", 25)(30, "div", 26);
1148
- i0.ɵɵtemplate(31, AIPromptFormComponentExtended_form_1_Conditional_31_Template, 3, 0, "kendo-button", 27);
1158
+ i0.ɵɵelementStart(29, "div", 24)(30, "div", 25);
1159
+ i0.ɵɵtemplate(31, AIPromptFormComponentExtended_form_1_Conditional_31_Template, 3, 2, "button", 26);
1149
1160
  i0.ɵɵelementEnd();
1150
- i0.ɵɵtemplate(32, AIPromptFormComponentExtended_form_1_Conditional_32_Template, 4, 3, "div", 28);
1161
+ i0.ɵɵtemplate(32, AIPromptFormComponentExtended_form_1_Conditional_32_Template, 4, 3, "div", 27);
1151
1162
  i0.ɵɵelementEnd()()();
1152
- i0.ɵɵelementStart(33, "div", 29)(34, "kendo-expansionpanel", 30);
1153
- i0.ɵɵtemplate(35, AIPromptFormComponentExtended_form_1_ng_template_35_Template, 4, 1, "ng-template", 31);
1154
- i0.ɵɵelementStart(36, "div", 32);
1155
- i0.ɵɵtemplate(37, AIPromptFormComponentExtended_form_1_Conditional_37_Template, 3, 0, "div", 33)(38, AIPromptFormComponentExtended_form_1_Conditional_38_Template, 13, 0, "div", 34)(39, AIPromptFormComponentExtended_form_1_Conditional_39_Template, 13, 0, "div", 35)(40, AIPromptFormComponentExtended_form_1_Conditional_40_Template, 4, 2, "div", 36);
1163
+ i0.ɵɵelementStart(33, "div", 28)(34, "kendo-expansionpanel", 29);
1164
+ i0.ɵɵtemplate(35, AIPromptFormComponentExtended_form_1_ng_template_35_Template, 4, 1, "ng-template", 30);
1165
+ i0.ɵɵelementStart(36, "div", 31);
1166
+ i0.ɵɵtemplate(37, AIPromptFormComponentExtended_form_1_Conditional_37_Template, 3, 0, "div", 32)(38, AIPromptFormComponentExtended_form_1_Conditional_38_Template, 13, 2, "div", 33)(39, AIPromptFormComponentExtended_form_1_Conditional_39_Template, 13, 2, "div", 34)(40, AIPromptFormComponentExtended_form_1_Conditional_40_Template, 4, 2, "div", 35);
1156
1167
  i0.ɵɵelementEnd()();
1157
- i0.ɵɵtemplate(41, AIPromptFormComponentExtended_form_1_Conditional_41_Template, 6, 2, "kendo-expansionpanel", 30);
1158
- i0.ɵɵelementStart(42, "kendo-expansionpanel", 30);
1159
- i0.ɵɵtemplate(43, AIPromptFormComponentExtended_form_1_ng_template_43_Template, 3, 0, "ng-template", 31);
1160
- i0.ɵɵelementStart(44, "div", 37)(45, "div", 38)(46, "div");
1161
- i0.ɵɵelement(47, "mj-form-field", 39);
1162
- i0.ɵɵtemplate(48, AIPromptFormComponentExtended_form_1_Conditional_48_Template, 1, 3, "mj-form-field", 40)(49, AIPromptFormComponentExtended_form_1_Conditional_49_Template, 1, 3, "mj-form-field", 41);
1163
- i0.ɵɵelement(50, "mj-form-field", 42);
1168
+ i0.ɵɵtemplate(41, AIPromptFormComponentExtended_form_1_Conditional_41_Template, 6, 2, "kendo-expansionpanel", 29);
1169
+ i0.ɵɵelementStart(42, "kendo-expansionpanel", 29);
1170
+ i0.ɵɵtemplate(43, AIPromptFormComponentExtended_form_1_ng_template_43_Template, 3, 0, "ng-template", 30);
1171
+ i0.ɵɵelementStart(44, "div", 36)(45, "div", 37)(46, "div");
1172
+ i0.ɵɵelement(47, "mj-form-field", 38);
1173
+ i0.ɵɵtemplate(48, AIPromptFormComponentExtended_form_1_Conditional_48_Template, 1, 3, "mj-form-field", 39)(49, AIPromptFormComponentExtended_form_1_Conditional_49_Template, 1, 3, "mj-form-field", 40);
1174
+ i0.ɵɵelement(50, "mj-form-field", 41);
1164
1175
  i0.ɵɵelementEnd();
1165
1176
  i0.ɵɵelementStart(51, "div");
1166
- i0.ɵɵelement(52, "mj-form-field", 43)(53, "mj-form-field", 44);
1167
- i0.ɵɵelementStart(54, "div", 45)(55, "label", 46);
1177
+ i0.ɵɵelement(52, "mj-form-field", 42)(53, "mj-form-field", 43);
1178
+ i0.ɵɵelementStart(54, "div", 44)(55, "label", 45);
1168
1179
  i0.ɵɵtext(56, " Result Selector Prompt ");
1169
1180
  i0.ɵɵelementEnd();
1170
- i0.ɵɵtemplate(57, AIPromptFormComponentExtended_form_1_Conditional_57_Template, 2, 1)(58, AIPromptFormComponentExtended_form_1_Conditional_58_Template, 2, 1, "span", 47);
1181
+ i0.ɵɵtemplate(57, AIPromptFormComponentExtended_form_1_Conditional_57_Template, 2, 1)(58, AIPromptFormComponentExtended_form_1_Conditional_58_Template, 2, 1, "span", 46);
1171
1182
  i0.ɵɵelementEnd()()()()();
1172
- i0.ɵɵtemplate(59, AIPromptFormComponentExtended_form_1_Conditional_59_Template, 6, 2, "kendo-expansionpanel", 30)(60, AIPromptFormComponentExtended_form_1_Conditional_60_Template, 6, 2, "kendo-expansionpanel", 30)(61, AIPromptFormComponentExtended_form_1_Conditional_61_Template, 4, 6, "kendo-expansionpanel", 30)(62, AIPromptFormComponentExtended_form_1_Conditional_62_Template, 12, 11, "kendo-expansionpanel", 30);
1183
+ i0.ɵɵtemplate(59, AIPromptFormComponentExtended_form_1_Conditional_59_Template, 6, 2, "kendo-expansionpanel", 29)(60, AIPromptFormComponentExtended_form_1_Conditional_60_Template, 6, 2, "kendo-expansionpanel", 29)(61, AIPromptFormComponentExtended_form_1_Conditional_61_Template, 4, 6, "kendo-expansionpanel", 29)(62, AIPromptFormComponentExtended_form_1_Conditional_62_Template, 12, 11, "kendo-expansionpanel", 29);
1173
1184
  i0.ɵɵelementEnd()()();
1174
1185
  } if (rf & 2) {
1175
1186
  const ctx_r1 = i0.ɵɵnextContext();
@@ -1226,12 +1237,12 @@ function AIPromptFormComponentExtended_form_1_Template(rf, ctx) { if (rf & 1) {
1226
1237
  i0.ɵɵadvance();
1227
1238
  i0.ɵɵconditional(ctx_r1.record.IsSaved ? 62 : -1);
1228
1239
  } }
1229
- function AIPromptFormComponentExtended_Conditional_3_Template(rf, ctx) { if (rf & 1) {
1240
+ function AIPromptFormComponentExtended_Conditional_2_Template(rf, ctx) { if (rf & 1) {
1230
1241
  const _r29 = i0.ɵɵgetCurrentView();
1231
- i0.ɵɵelementStart(0, "kendo-window", 181);
1232
- i0.ɵɵlistener("close", function AIPromptFormComponentExtended_Conditional_3_Template_kendo_window_close_0_listener() { i0.ɵɵrestoreView(_r29); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.onTestHarnessVisibilityChanged(false)); });
1233
- i0.ɵɵelementStart(1, "mj-ai-test-harness", 182);
1234
- i0.ɵɵlistener("visibilityChange", function AIPromptFormComponentExtended_Conditional_3_Template_mj_ai_test_harness_visibilityChange_1_listener($event) { i0.ɵɵrestoreView(_r29); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.onTestHarnessVisibilityChanged($event)); });
1242
+ i0.ɵɵelementStart(0, "kendo-window", 180);
1243
+ i0.ɵɵlistener("close", function AIPromptFormComponentExtended_Conditional_2_Template_kendo_window_close_0_listener() { i0.ɵɵrestoreView(_r29); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.onTestHarnessVisibilityChanged(false)); });
1244
+ i0.ɵɵelementStart(1, "mj-ai-test-harness", 181);
1245
+ i0.ɵɵlistener("visibilityChange", function AIPromptFormComponentExtended_Conditional_2_Template_mj_ai_test_harness_visibilityChange_1_listener($event) { i0.ɵɵrestoreView(_r29); const ctx_r1 = i0.ɵɵnextContext(); return i0.ɵɵresetView(ctx_r1.onTestHarnessVisibilityChanged($event)); });
1235
1246
  i0.ɵɵelementEnd()();
1236
1247
  } if (rf & 2) {
1237
1248
  const ctx_r1 = i0.ɵɵnextContext();
@@ -1256,7 +1267,6 @@ let AIPromptFormComponentExtended = class AIPromptFormComponentExtended extends
1256
1267
  this.templateContent = null;
1257
1268
  this.isLoadingTemplate = true; // Default to loading state
1258
1269
  this.templateNotFoundInDatabase = false;
1259
- this.showExecutionDialog = false;
1260
1270
  this.showTestHarness = false;
1261
1271
  // Model management
1262
1272
  this.promptModels = [];
@@ -1451,7 +1461,8 @@ let AIPromptFormComponentExtended = class AIPromptFormComponentExtended extends
1451
1461
  MJNotificationService.Instance.CreateSimpleNotification('AI prompt must be Active to execute', 'warning', 4000);
1452
1462
  return;
1453
1463
  }
1454
- this.showExecutionDialog = true;
1464
+ // Use test harness instead
1465
+ this.openTestHarness();
1455
1466
  }
1456
1467
  /**
1457
1468
  * Opens the test harness
@@ -2258,24 +2269,17 @@ let AIPromptFormComponentExtended = class AIPromptFormComponentExtended extends
2258
2269
  } if (rf & 2) {
2259
2270
  let _t;
2260
2271
  i0.ɵɵqueryRefresh(_t = i0.ɵɵloadQuery()) && (ctx.templateEditor = _t.first);
2261
- } }, features: [i0.ɵɵInheritDefinitionFeature], decls: 4, vars: 6, consts: [["form", "ngForm"], ["templateEditor", ""], ["mjFillContainer", "", 1, "record-form-container", 3, "bottomMargin", "rightMargin"], ["class", "record-form", "mjFillContainer", "", 4, "ngIf"], [3, "isVisibleChange", "aiPrompt", "isVisible"], [3, "width", "height", "minWidth", "minHeight", "draggable", "resizable", "state", "title"], ["mjFillContainer", "", 1, "record-form"], [3, "form"], [1, "prompt-main-area", 2, "display", "flex", "flex-direction", "column", "height", "100%", "overflow-y", "auto"], [1, "prompt-header", 2, "flex-shrink", "0", "padding", "20px", "background", "#f8f9fa", "border-bottom", "2px solid #e9ecef"], [2, "display", "flex", "justify-content", "space-between", "align-items", "flex-start", "gap", "20px"], [2, "flex", "1", "min-width", "0"], [2, "display", "flex", "align-items", "center", "gap", "12px", "margin-bottom", "8px"], [1, "fa-solid", "fa-robot", 2, "color", "#6f42c1", "font-size", "1.4em"], ["name", "promptName", "placeholder", "Enter prompt name...", 2, "font-size", "1.2em", "font-weight", "600", "min-width", "300px", "flex", "1", 3, "ngModel"], [2, "display", "flex", "gap", "16px", "margin-bottom", "12px", "flex-wrap", "wrap"], ["name", "promptDescription", "placeholder", "Enter prompt description...", 2, "width", "100%", "max-width", "600px", "margin-bottom", "12px", 3, "ngModel", "rows"], [2, "margin", "0 0 12px 0", "color", "#6c757d", "font-size", "0.9em", "line-height", "1.4"], [1, "quick-config", 2, "display", "flex", "align-items", "center", "gap", "16px", "flex-wrap", "wrap"], [1, "config-item", 2, "display", "flex", "align-items", "center", "gap", "6px", "font-size", "0.85em"], [1, "fa-solid", "fa-layer-group", 2, "color", "#6c757d"], [2, "color", "#6c757d"], [2, "color", "#495057", "font-weight", "500"], [1, "fa-solid", "fa-code", 2, "color", "#6c757d"], [2, "font-weight", "500"], [1, "action-buttons", 2, "display", "flex", "flex-direction", "column", "gap", "8px", "align-items", "flex-end"], [2, "display", "flex", "gap", "8px"], ["themeColor", "primary", "size", "large", "title", "Run AI Prompt Test Harness"], [2, "font-size", "0.75em", "color", "#dc3545", "text-align", "right", "max-width", "200px"], [1, "configuration-sections", 2, "flex", "1", "background", "white", "border-top", "2px solid #e9ecef", "padding", "16px", "min-height", "0"], [2, "margin-bottom", "12px", 3, "expanded"], ["kendoExpansionPanelTitleDirective", ""], [1, "template-section", 2, "display", "flex", "flex-direction", "column", "min-height", "400px", "padding", "8px"], [1, "loading-state", 2, "flex", "1", "display", "flex", "align-items", "center", "justify-content", "center", "color", "#6c757d"], [1, "no-template-state", 2, "flex", "1", "display", "flex", "flex-direction", "column", "align-items", "center", "justify-content", "center", "padding", "40px", "color", "#6c757d"], [1, "invalid-template-state", 2, "flex", "1", "display", "flex", "flex-direction", "column", "align-items", "center", "justify-content", "center", "padding", "40px", "color", "#dc3545"], [1, "template-editor-container", 2, "flex", "1", "display", "flex", "flex-direction", "column", "min-height", "350px"], [2, "padding", "16px 0"], [2, "display", "grid", "grid-template-columns", "1fr 1fr", "gap", "20px"], ["FieldName", "ParallelizationMode", "Type", "dropdownlist", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "ParallelCount", "Type", "numerictextbox", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "ParallelConfigParam", "Type", "textbox", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "OutputType", "Type", "dropdownlist", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "ValidationBehavior", "Type", "dropdownlist", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "EnableCaching", "Type", "checkbox", 3, "record", "ShowLabel", "EditMode"], [2, "margin-bottom", "16px"], [2, "display", "block", "margin-bottom", "4px", "font-weight", "600", "color", "#495057", "font-size", "0.9em"], [2, "color", "#495057"], ["name", "promptName", "placeholder", "Enter prompt name...", 2, "font-size", "1.2em", "font-weight", "600", "min-width", "300px", "flex", "1", 3, "ngModelChange", "ngModel"], [2, "margin", "0", "color", "#495057", "font-weight", "600", "flex", "1"], [1, "status-badge", 2, "color", "white", "padding", "4px 10px", "border-radius", "12px", "font-size", "0.75em", "font-weight", "500"], ["name", "promptStatus", "textField", "text", "valueField", "value", 2, "width", "150px", 3, "ngModelChange", "ngModel", "data", "valuePrimitive"], [2, "color", "#dc3545"], [2, "padding", "8px", "color", "#6c757d", "font-style", "italic", "width", "200px"], ["name", "promptTypeID", "textField", "Name", "valueField", "ID", "placeholder", "Select prompt type...", 2, "width", "200px", 3, "ngModel", "data", "valuePrimitive", "filterable"], [1, "fa-solid", "fa-spinner", "fa-spin"], ["name", "promptTypeID", "textField", "Name", "valueField", "ID", "placeholder", "Select prompt type...", 2, "width", "200px", 3, "ngModelChange", "ngModel", "data", "valuePrimitive", "filterable"], ["name", "promptDescription", "placeholder", "Enter prompt description...", 2, "width", "100%", "max-width", "600px", "margin-bottom", "12px", 3, "ngModelChange", "ngModel", "rows"], [1, "fa-solid", "fa-tag", 2, "color", "#6c757d"], [1, "fa-solid", "fa-database", 2, "color", "#28a745"], [2, "color", "#28a745", "font-weight", "500"], ["themeColor", "primary", "size", "large", "title", "Run AI Prompt Test Harness", 3, "click"], [1, "fa-solid", "fa-play"], [2, "display", "flex", "align-items", "center", "gap", "8px", "font-weight", "600"], [2, "color", "#6c757d", "font-size", "0.9em", "font-weight", "normal"], [1, "fa-solid", "fa-spinner", "fa-spin", 2, "font-size", "24px", "margin-right", "12px"], [1, "fa-solid", "fa-code", 2, "font-size", "64px", "margin-bottom", "20px", "opacity", "0.3"], [2, "margin-bottom", "12px", "color", "#495057"], [2, "margin-bottom", "24px", "text-align", "center", "max-width", "400px"], [2, "display", "flex", "gap", "12px"], ["themeColor", "primary", 3, "click"], [1, "fa-solid", "fa-plus"], ["fillMode", "outline", 3, "click"], [1, "fa-solid", "fa-link"], [1, "fa-solid", "fa-exclamation-triangle", 2, "font-size", "64px", "margin-bottom", "20px", "opacity", "0.7"], [2, "margin-bottom", "12px"], [1, "fa-solid", "fa-refresh"], [2, "flex", "1", "background", "white", "border-radius", "6px", "border", "1px solid #e9ecef"], [2, "display", "block", "min-height", "300px", 3, "contentChange", "runTemplate", "template", "config"], [1, "model-management", 2, "border", "1px solid #dee2e6", "border-radius", "6px", "background", "#f8f9fa"], [1, "loading-state", 2, "padding", "20px", "text-align", "center", "color", "#6c757d"], [1, "fa-solid", "fa-microchip", 2, "color", "#6c757d"], [1, "badge", 2, "background", "#17a2b8", "color", "white", "padding", "2px 6px", "border-radius", "10px", "font-size", "0.7em"], [2, "color", "#6c757d", "font-size", "0.8em", "font-weight", "normal", "margin-left", "8px"], ["title", "Models are tried in order from top to bottom. The first available model will be used.", 1, "fa-solid", "fa-info-circle"], [1, "empty-state", 2, "padding", "20px", "text-align", "center", "color", "#6c757d"], [1, "fa-solid", "fa-info-circle"], [2, "margin-top", "10px"], ["fillMode", "outline", "themeColor", "primary", "size", "small", 3, "click"], [2, "padding", "12px 16px", "background", "#e3f2fd", "border-bottom", "1px solid #bbdefb", "color", "#1565c0", "font-size", "0.85em"], [1, "model-header", 2, "display", "grid", "grid-template-columns", "40px 2fr 1fr 1fr 60px", "gap", "12px", "padding", "12px 16px", "background", "#e9ecef", "font-weight", "600", "font-size", "0.85em", "color", "#495057", "border-bottom", "1px solid #dee2e6"], ["title", "Priority order - models are tried from top to bottom"], [1, "fa-solid", "fa-sort", 2, "color", "#6c757d"], [1, "add-model-row", 2, "padding", "12px 16px", "text-align", "center", "background", "#f8f9fa", "border-top", "1px solid #dee2e6"], [1, "fa-solid", "fa-info-circle", 2, "margin-right", "6px"], [1, "model-row", 2, "display", "grid", "grid-template-columns", "40px 2fr 1fr 1fr 60px", "gap", "12px", "padding", "12px 16px", "border-bottom", "1px solid #e9ecef", "align-items", "start", "transition", "background 0.2s, opacity 0.2s", 3, "dragstart", "dragover", "drop", "dragend", "draggable"], [1, "drag-handle", 2, "display", "flex", "flex-direction", "column", "align-items", "center", "justify-content", "center", "color", "#6c757d"], [2, "font-size", "0.9em", "font-weight", "600", 3, "title"], [1, "model-select"], ["textField", "Name", "valueField", "ID", "placeholder", "Select a model...", 2, "width", "100%", 3, "ngModel", "name", "data", "valuePrimitive", "filterable"], [1, "model-vendor"], [1, "model-created"], [2, "color", "#6c757d", "font-size", "0.8em"], [2, "color", "#28a745", "font-size", "0.8em", "font-style", "italic"], [1, "model-actions", 2, "display", "flex", "gap", "2px", "flex-direction", "column"], [2, "display", "grid", "grid-template-columns", "40px 1fr", "gap", "12px", "padding", "8px 16px", "border-bottom", "1px solid #e9ecef", "background", "#f8f9fa", "font-size", "0.85em", "color", "#6c757d"], [2, "display", "flex", "gap", "16px", "flex-wrap", "wrap", "align-items", "center", "margin-bottom", "8px"], [2, "padding", "8px", "background", "#fff", "border", "1px solid #dee2e6", "border-radius", "4px", "margin-top", "8px"], ["title", "Drag to reorder priority", 1, "fa-solid", "fa-grip-vertical", 2, "cursor", "move"], [2, "font-size", "0.7em", "margin-top", "2px"], ["textField", "Name", "valueField", "ID", "placeholder", "Select a model...", 2, "width", "100%", 3, "ngModelChange", "valueChange", "ngModel", "name", "data", "valuePrimitive", "filterable"], [2, "color", "#6c757d", "font-style", "italic", "font-size", "0.9em"], ["textField", "Name", "valueField", "ID", "placeholder", "Select vendor...", 2, "width", "100%", 3, "ngModel", "name", "data", "valuePrimitive", "filterable"], ["textField", "Name", "valueField", "ID", "placeholder", "Select vendor...", 2, "width", "100%", 3, "ngModelChange", "ngModel", "name", "data", "valuePrimitive", "filterable"], ["kendoDropDownListItemTemplate", ""], [2, "font-size", "0.8em", "margin-left", "4px"], [2, "font-size", "0.9em", "font-weight", "500", 3, "color"], [2, "font-size", "0.9em", "font-weight", "500"], [2, "font-size", "0.9em", 3, "color"], [2, "color", "#6c757d", "font-size", "0.9em"], [2, "font-size", "0.9em"], [2, "display", "flex", "gap", "2px", "margin-bottom", "4px"], ["fillMode", "flat", "size", "small", "title", "Move up", 3, "click", "disabled"], [1, "fa-solid", "fa-chevron-up"], ["fillMode", "flat", "size", "small", "title", "Move down", 3, "click", "disabled"], [1, "fa-solid", "fa-chevron-down"], ["fillMode", "flat", "themeColor", "error", "size", "small", "title", "Remove model", 3, "click"], [1, "fa-solid", "fa-times"], [2, "margin-bottom", "6px", "font-weight", "600", "color", "#495057", "font-size", "0.9em"], [1, "fa-solid", "fa-layer-group"], [2, "display", "grid", "grid-template-columns", "1fr 1fr 1fr", "gap", "12px", "align-items", "center"], [2, "display", "flex", "gap", "16px", "flex-wrap", "wrap", "align-items", "center"], [2, "display", "block", "margin-bottom", "2px", "font-size", "0.8em", "font-weight", "600", "color", "#495057"], ["textField", "text", "valueField", "value", "placeholder", "Select mode...", 2, "width", "100%", "font-size", "0.85em", 3, "ngModelChange", "ngModel", "name", "data", "valuePrimitive"], ["placeholder", "Count...", 2, "width", "100%", "font-size", "0.85em", 3, "ngModelChange", "ngModel", "name", "min", "step", "format"], ["placeholder", "Parameter name...", 2, "width", "100%", "font-size", "0.85em", 3, "ngModelChange", "ngModel", "name"], ["fillMode", "outline", "themeColor", "success", "size", "small", 3, "click"], [1, "fa-solid", "fa-cogs", 2, "color", "#6c757d"], [2, "padding", "8px", "color", "#6c757d", "font-style", "italic"], ["name", "resultSelectorPromptID", "textField", "text", "valueField", "value", "placeholder", "Select a result selector prompt...", 2, "width", "100%", 3, "ngModel", "data", "valuePrimitive", "filterable"], ["name", "resultSelectorPromptID", "textField", "text", "valueField", "value", "placeholder", "Select a result selector prompt...", 2, "width", "100%", 3, "ngModelChange", "valueChange", "ngModel", "data", "valuePrimitive", "filterable"], [2, "padding", "16px"], [2, "background", "#f8f9fa", "border", "1px solid #dee2e6", "border-radius", "4px", "padding", "12px", "font-family", "'Courier New', monospace", "font-size", "0.9em", "white-space", "pre-wrap", "overflow", "auto", "max-height", "250px"], [2, "background", "#fff3cd", "border", "1px solid #ffeaa7", "border-radius", "4px", "padding", "12px", "color", "#856404", "text-align", "center"], [2, "color", "#dc3545", "font-size", "0.8em", "font-weight", "normal"], ["name", "outputExample", "language", "json", "placeholder", "Enter JSON example structure...", 2, "width", "100%", "height", "200px", "border", "1px solid #dee2e6", "border-radius", "4px", 3, "ngModelChange", "ngModel"], [2, "margin-top", "8px", "color", "#6c757d", "font-size", "0.85em"], [1, "fa-solid", "fa-exclamation-triangle"], [2, "text-align", "center", "padding", "40px", "color", "#6c757d"], [1, "fa-solid", "fa-history", 2, "color", "#6c757d"], [2, "color", "#6c757d", "font-weight", "normal"], [1, "fa-solid", "fa-spinner", "fa-spin", 2, "font-size", "2em", "margin-bottom", "12px"], [1, "fa-solid", "fa-history", 2, "font-size", "3em", "margin-bottom", "12px", "opacity", "0.3"], [2, "display", "flex", "justify-content", "space-between", "align-items", "center", "margin-bottom", "16px"], [2, "display", "flex", "gap", "8px", "align-items", "center"], [2, "color", "#6c757d", "font-size", "0.85em"], ["selection", "single"], ["kendoButton", "", "size", "small", 3, "click", "selected"], [2, "margin-left", "4px", "font-size", "0.8em", 3, "class"], [2, "border", "1px solid #e9ecef", "border-radius", "8px", "overflow", "hidden"], [2, "width", "100%", "border-collapse", "collapse"], [2, "background", "#f8f9fa", "border-bottom", "2px solid #e9ecef"], [2, "padding", "12px", "text-align", "left", "font-weight", "600", "color", "#495057"], [2, "padding", "12px", "text-align", "right", "font-weight", "600", "color", "#495057"], [2, "padding", "12px", "text-align", "center", "font-weight", "600", "color", "#495057"], [1, "history-row", 2, "border-bottom", "1px solid #f1f3f5", 3, "even-row"], [2, "margin-left", "4px", "font-size", "0.8em"], [1, "history-row", 2, "border-bottom", "1px solid #f1f3f5"], [2, "padding", "12px"], [2, "display", "flex", "align-items", "center", "gap", "6px"], [2, "padding", "12px", "color", "#495057"], [2, "padding", "12px", "text-align", "right", "color", "#495057"], [2, "padding", "12px", "text-align", "center"], [2, "padding", "4px 8px", "border-radius", "12px", "background", "#e9ecef", "color", "#495057", "font-size", "0.85em", "font-weight", "500"], ["fillMode", "flat", "size", "small", "title", "View details", 3, "click"], [1, "fa-solid", "fa-external-link"], [2, "height", "300px", 3, "Params", "NewRecordValues", "AllowLoad", "EditMode", "BottomMargin"], [1, "fa-solid", "fa-database", 2, "color", "#6c757d"], [2, "margin", "0 0 12px 0", "color", "#495057"], [2, "height", "200px", 3, "Params", "NewRecordValues", "AllowLoad", "EditMode", "BottomMargin"], [1, "fa-solid", "fa-link", 2, "color", "#6c757d"], [3, "close", "width", "height", "minWidth", "minHeight", "draggable", "resizable", "state", "title"], [3, "visibilityChange", "entity", "mode", "isVisible"]], template: function AIPromptFormComponentExtended_Template(rf, ctx) { if (rf & 1) {
2272
+ } }, features: [i0.ɵɵInheritDefinitionFeature], decls: 3, vars: 4, consts: [["form", "ngForm"], ["templateEditor", ""], ["mjFillContainer", "", 1, "record-form-container", 3, "bottomMargin", "rightMargin"], ["class", "record-form", "mjFillContainer", "", 4, "ngIf"], [3, "width", "height", "minWidth", "minHeight", "draggable", "resizable", "state", "title"], ["mjFillContainer", "", 1, "record-form"], [3, "form"], [1, "prompt-main-area", 2, "display", "flex", "flex-direction", "column", "height", "100%", "overflow-y", "auto"], [1, "prompt-header", 2, "flex-shrink", "0", "padding", "20px", "background", "#f8f9fa", "border-bottom", "2px solid #e9ecef"], [2, "display", "flex", "justify-content", "space-between", "align-items", "flex-start", "gap", "20px"], [2, "flex", "1", "min-width", "0"], [2, "display", "flex", "align-items", "center", "gap", "12px", "margin-bottom", "8px"], [1, "fa-solid", "fa-robot", 2, "color", "#6f42c1", "font-size", "1.4em"], ["name", "promptName", "placeholder", "Enter prompt name...", 2, "font-size", "1.2em", "font-weight", "600", "min-width", "300px", "flex", "1", 3, "ngModel"], [2, "display", "flex", "gap", "16px", "margin-bottom", "12px", "flex-wrap", "wrap"], ["name", "promptDescription", "placeholder", "Enter prompt description...", 2, "width", "100%", "max-width", "600px", "margin-bottom", "12px", 3, "ngModel", "rows"], [2, "margin", "0 0 12px 0", "color", "#6c757d", "font-size", "0.9em", "line-height", "1.4"], [1, "quick-config", 2, "display", "flex", "align-items", "center", "gap", "16px", "flex-wrap", "wrap"], [1, "config-item", 2, "display", "flex", "align-items", "center", "gap", "6px", "font-size", "0.85em"], [1, "fa-solid", "fa-layer-group", 2, "color", "#6c757d"], [2, "color", "#6c757d"], [2, "color", "#495057", "font-weight", "500"], [1, "fa-solid", "fa-code", 2, "color", "#6c757d"], [2, "font-weight", "500"], [1, "action-buttons", 2, "display", "flex", "flex-direction", "column", "gap", "8px", "align-items", "flex-end"], [2, "display", "flex", "gap", "8px"], ["kendoButton", "", "title", "Run AI Prompt Test Harness", 3, "themeColor", "size"], [2, "font-size", "0.75em", "color", "#dc3545", "text-align", "right", "max-width", "200px"], [1, "configuration-sections", 2, "flex", "1", "background", "white", "border-top", "2px solid #e9ecef", "padding", "16px", "min-height", "0"], [2, "margin-bottom", "12px", 3, "expanded"], ["kendoExpansionPanelTitleDirective", ""], [1, "template-section", 2, "display", "flex", "flex-direction", "column", "min-height", "400px", "padding", "8px"], [1, "loading-state", 2, "flex", "1", "display", "flex", "align-items", "center", "justify-content", "center", "color", "#6c757d"], [1, "no-template-state", 2, "flex", "1", "display", "flex", "flex-direction", "column", "align-items", "center", "justify-content", "center", "padding", "40px", "color", "#6c757d"], [1, "invalid-template-state", 2, "flex", "1", "display", "flex", "flex-direction", "column", "align-items", "center", "justify-content", "center", "padding", "40px", "color", "#dc3545"], [1, "template-editor-container", 2, "flex", "1", "display", "flex", "flex-direction", "column", "min-height", "350px"], [2, "padding", "16px 0"], [2, "display", "grid", "grid-template-columns", "1fr 1fr", "gap", "20px"], ["FieldName", "ParallelizationMode", "Type", "dropdownlist", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "ParallelCount", "Type", "numerictextbox", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "ParallelConfigParam", "Type", "textbox", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "OutputType", "Type", "dropdownlist", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "ValidationBehavior", "Type", "dropdownlist", 3, "record", "ShowLabel", "EditMode"], ["FieldName", "EnableCaching", "Type", "checkbox", 3, "record", "ShowLabel", "EditMode"], [2, "margin-bottom", "16px"], [2, "display", "block", "margin-bottom", "4px", "font-weight", "600", "color", "#495057", "font-size", "0.9em"], [2, "color", "#495057"], ["name", "promptName", "placeholder", "Enter prompt name...", 2, "font-size", "1.2em", "font-weight", "600", "min-width", "300px", "flex", "1", 3, "ngModelChange", "ngModel"], [2, "margin", "0", "color", "#495057", "font-weight", "600", "flex", "1"], [1, "status-badge", 2, "color", "white", "padding", "4px 10px", "border-radius", "12px", "font-size", "0.75em", "font-weight", "500"], ["name", "promptStatus", "textField", "text", "valueField", "value", 2, "width", "150px", 3, "ngModelChange", "ngModel", "data", "valuePrimitive"], [2, "color", "#dc3545"], [2, "padding", "8px", "color", "#6c757d", "font-style", "italic", "width", "200px"], ["name", "promptTypeID", "textField", "Name", "valueField", "ID", "placeholder", "Select prompt type...", 2, "width", "200px", 3, "ngModel", "data", "valuePrimitive", "filterable"], [1, "fa-solid", "fa-spinner", "fa-spin"], ["name", "promptTypeID", "textField", "Name", "valueField", "ID", "placeholder", "Select prompt type...", 2, "width", "200px", 3, "ngModelChange", "ngModel", "data", "valuePrimitive", "filterable"], ["name", "promptDescription", "placeholder", "Enter prompt description...", 2, "width", "100%", "max-width", "600px", "margin-bottom", "12px", 3, "ngModelChange", "ngModel", "rows"], [1, "fa-solid", "fa-tag", 2, "color", "#6c757d"], [1, "fa-solid", "fa-database", 2, "color", "#28a745"], [2, "color", "#28a745", "font-weight", "500"], ["kendoButton", "", "title", "Run AI Prompt Test Harness", 3, "click", "themeColor", "size"], [1, "fa-solid", "fa-play"], [2, "display", "flex", "align-items", "center", "gap", "8px", "font-weight", "600"], [2, "color", "#6c757d", "font-size", "0.9em", "font-weight", "normal"], [1, "fa-solid", "fa-spinner", "fa-spin", 2, "font-size", "24px", "margin-right", "12px"], [1, "fa-solid", "fa-code", 2, "font-size", "64px", "margin-bottom", "20px", "opacity", "0.3"], [2, "margin-bottom", "12px", "color", "#495057"], [2, "margin-bottom", "24px", "text-align", "center", "max-width", "400px"], [2, "display", "flex", "gap", "12px"], ["kendoButton", "", 3, "click", "themeColor"], [1, "fa-solid", "fa-plus"], ["kendoButton", "", 3, "click", "fillMode"], [1, "fa-solid", "fa-link"], [1, "fa-solid", "fa-exclamation-triangle", 2, "font-size", "64px", "margin-bottom", "20px", "opacity", "0.7"], [2, "margin-bottom", "12px"], [1, "fa-solid", "fa-refresh"], [2, "flex", "1", "background", "white", "border-radius", "6px", "border", "1px solid #e9ecef"], [2, "display", "block", "min-height", "300px", 3, "contentChange", "runTemplate", "template", "config"], [1, "model-management", 2, "border", "1px solid #dee2e6", "border-radius", "6px", "background", "#f8f9fa"], [1, "loading-state", 2, "padding", "20px", "text-align", "center", "color", "#6c757d"], [1, "fa-solid", "fa-microchip", 2, "color", "#6c757d"], [1, "badge", 2, "background", "#17a2b8", "color", "white", "padding", "2px 6px", "border-radius", "10px", "font-size", "0.7em"], [2, "color", "#6c757d", "font-size", "0.8em", "font-weight", "normal", "margin-left", "8px"], ["title", "Models are tried in order from top to bottom. The first available model will be used.", 1, "fa-solid", "fa-info-circle"], [1, "empty-state", 2, "padding", "20px", "text-align", "center", "color", "#6c757d"], [1, "fa-solid", "fa-info-circle"], [2, "margin-top", "10px"], ["kendoButton", "", "fillMode", "outline", "themeColor", "primary", "size", "small", 3, "click"], [2, "padding", "12px 16px", "background", "#e3f2fd", "border-bottom", "1px solid #bbdefb", "color", "#1565c0", "font-size", "0.85em"], [1, "model-header", 2, "display", "grid", "grid-template-columns", "40px 2fr 1fr 1fr 60px", "gap", "12px", "padding", "12px 16px", "background", "#e9ecef", "font-weight", "600", "font-size", "0.85em", "color", "#495057", "border-bottom", "1px solid #dee2e6"], ["title", "Priority order - models are tried from top to bottom"], [1, "fa-solid", "fa-sort", 2, "color", "#6c757d"], [1, "add-model-row", 2, "padding", "12px 16px", "text-align", "center", "background", "#f8f9fa", "border-top", "1px solid #dee2e6"], [1, "fa-solid", "fa-info-circle", 2, "margin-right", "6px"], [1, "model-row", 2, "display", "grid", "grid-template-columns", "40px 2fr 1fr 1fr 60px", "gap", "12px", "padding", "12px 16px", "border-bottom", "1px solid #e9ecef", "align-items", "start", "transition", "background 0.2s, opacity 0.2s", 3, "dragstart", "dragover", "drop", "dragend", "draggable"], [1, "drag-handle", 2, "display", "flex", "flex-direction", "column", "align-items", "center", "justify-content", "center", "color", "#6c757d"], [2, "font-size", "0.9em", "font-weight", "600", 3, "title"], [1, "model-select"], ["textField", "Name", "valueField", "ID", "placeholder", "Select a model...", 2, "width", "100%", 3, "ngModel", "name", "data", "valuePrimitive", "filterable"], [1, "model-vendor"], [1, "model-created"], [2, "color", "#6c757d", "font-size", "0.8em"], [2, "color", "#28a745", "font-size", "0.8em", "font-style", "italic"], [1, "model-actions", 2, "display", "flex", "gap", "2px", "flex-direction", "column"], [2, "display", "grid", "grid-template-columns", "40px 1fr", "gap", "12px", "padding", "8px 16px", "border-bottom", "1px solid #e9ecef", "background", "#f8f9fa", "font-size", "0.85em", "color", "#6c757d"], [2, "display", "flex", "gap", "16px", "flex-wrap", "wrap", "align-items", "center", "margin-bottom", "8px"], [2, "padding", "8px", "background", "#fff", "border", "1px solid #dee2e6", "border-radius", "4px", "margin-top", "8px"], ["title", "Drag to reorder priority", 1, "fa-solid", "fa-grip-vertical", 2, "cursor", "move"], [2, "font-size", "0.7em", "margin-top", "2px"], ["textField", "Name", "valueField", "ID", "placeholder", "Select a model...", 2, "width", "100%", 3, "ngModelChange", "valueChange", "ngModel", "name", "data", "valuePrimitive", "filterable"], [2, "color", "#6c757d", "font-style", "italic", "font-size", "0.9em"], ["textField", "Name", "valueField", "ID", "placeholder", "Select vendor...", 2, "width", "100%", 3, "ngModel", "name", "data", "valuePrimitive", "filterable"], ["textField", "Name", "valueField", "ID", "placeholder", "Select vendor...", 2, "width", "100%", 3, "ngModelChange", "ngModel", "name", "data", "valuePrimitive", "filterable"], ["kendoDropDownListItemTemplate", ""], [2, "font-size", "0.8em", "margin-left", "4px"], [2, "font-size", "0.9em", "font-weight", "500", 3, "color"], [2, "font-size", "0.9em", "font-weight", "500"], [2, "font-size", "0.9em", 3, "color"], [2, "color", "#6c757d", "font-size", "0.9em"], [2, "font-size", "0.9em"], [2, "display", "flex", "gap", "2px", "margin-bottom", "4px"], ["kendoButton", "", "fillMode", "flat", "size", "small", "title", "Move up", 3, "click", "disabled"], [1, "fa-solid", "fa-chevron-up"], ["kendoButton", "", "fillMode", "flat", "size", "small", "title", "Move down", 3, "click", "disabled"], [1, "fa-solid", "fa-chevron-down"], ["kendoButton", "", "fillMode", "flat", "themeColor", "error", "size", "small", "title", "Remove model", 3, "click"], [1, "fa-solid", "fa-times"], [2, "margin-bottom", "6px", "font-weight", "600", "color", "#495057", "font-size", "0.9em"], [1, "fa-solid", "fa-layer-group"], [2, "display", "grid", "grid-template-columns", "1fr 1fr 1fr", "gap", "12px", "align-items", "center"], [2, "display", "flex", "gap", "16px", "flex-wrap", "wrap", "align-items", "center"], [2, "display", "block", "margin-bottom", "2px", "font-size", "0.8em", "font-weight", "600", "color", "#495057"], ["textField", "text", "valueField", "value", "placeholder", "Select mode...", 2, "width", "100%", "font-size", "0.85em", 3, "ngModelChange", "ngModel", "name", "data", "valuePrimitive"], ["placeholder", "Count...", 2, "width", "100%", "font-size", "0.85em", 3, "ngModelChange", "ngModel", "name", "min", "step", "format"], ["placeholder", "Parameter name...", 2, "width", "100%", "font-size", "0.85em", 3, "ngModelChange", "ngModel", "name"], ["kendoButton", "", "fillMode", "outline", "themeColor", "success", "size", "small", 3, "click"], [1, "fa-solid", "fa-cogs", 2, "color", "#6c757d"], [2, "padding", "8px", "color", "#6c757d", "font-style", "italic"], ["name", "resultSelectorPromptID", "textField", "text", "valueField", "value", "placeholder", "Select a result selector prompt...", 2, "width", "100%", 3, "ngModel", "data", "valuePrimitive", "filterable"], ["name", "resultSelectorPromptID", "textField", "text", "valueField", "value", "placeholder", "Select a result selector prompt...", 2, "width", "100%", 3, "ngModelChange", "valueChange", "ngModel", "data", "valuePrimitive", "filterable"], [2, "padding", "16px"], [2, "background", "#f8f9fa", "border", "1px solid #dee2e6", "border-radius", "4px", "padding", "12px", "font-family", "'Courier New', monospace", "font-size", "0.9em", "white-space", "pre-wrap", "overflow", "auto", "max-height", "250px"], [2, "background", "#fff3cd", "border", "1px solid #ffeaa7", "border-radius", "4px", "padding", "12px", "color", "#856404", "text-align", "center"], [2, "color", "#dc3545", "font-size", "0.8em", "font-weight", "normal"], ["name", "outputExample", "language", "json", "placeholder", "Enter JSON example structure...", 2, "width", "100%", "height", "200px", "border", "1px solid #dee2e6", "border-radius", "4px", 3, "ngModelChange", "ngModel"], [2, "margin-top", "8px", "color", "#6c757d", "font-size", "0.85em"], [1, "fa-solid", "fa-exclamation-triangle"], [2, "text-align", "center", "padding", "40px", "color", "#6c757d"], [1, "fa-solid", "fa-history", 2, "color", "#6c757d"], [2, "color", "#6c757d", "font-weight", "normal"], [1, "fa-solid", "fa-spinner", "fa-spin", 2, "font-size", "2em", "margin-bottom", "12px"], [1, "fa-solid", "fa-history", 2, "font-size", "3em", "margin-bottom", "12px", "opacity", "0.3"], [2, "display", "flex", "justify-content", "space-between", "align-items", "center", "margin-bottom", "16px"], [2, "display", "flex", "gap", "8px", "align-items", "center"], [2, "color", "#6c757d", "font-size", "0.85em"], ["selection", "single"], ["kendoButton", "", "size", "small", 3, "click", "selected"], [2, "margin-left", "4px", "font-size", "0.8em", 3, "class"], [2, "border", "1px solid #e9ecef", "border-radius", "8px", "overflow", "hidden"], [2, "width", "100%", "border-collapse", "collapse"], [2, "background", "#f8f9fa", "border-bottom", "2px solid #e9ecef"], [2, "padding", "12px", "text-align", "left", "font-weight", "600", "color", "#495057"], [2, "padding", "12px", "text-align", "right", "font-weight", "600", "color", "#495057"], [2, "padding", "12px", "text-align", "center", "font-weight", "600", "color", "#495057"], [1, "history-row", 2, "border-bottom", "1px solid #f1f3f5", 3, "even-row"], [2, "margin-left", "4px", "font-size", "0.8em"], [1, "history-row", 2, "border-bottom", "1px solid #f1f3f5"], [2, "padding", "12px"], [2, "display", "flex", "align-items", "center", "gap", "6px"], [2, "padding", "12px", "color", "#495057"], [2, "padding", "12px", "text-align", "right", "color", "#495057"], [2, "padding", "12px", "text-align", "center"], [2, "padding", "4px 8px", "border-radius", "12px", "background", "#e9ecef", "color", "#495057", "font-size", "0.85em", "font-weight", "500"], ["kendoButton", "", "fillMode", "flat", "size", "small", "title", "View details", 3, "click"], [1, "fa-solid", "fa-external-link"], [2, "height", "300px", 3, "Params", "NewRecordValues", "AllowLoad", "EditMode", "BottomMargin"], [1, "fa-solid", "fa-database", 2, "color", "#6c757d"], [2, "margin", "0 0 12px 0", "color", "#495057"], [2, "height", "200px", 3, "Params", "NewRecordValues", "AllowLoad", "EditMode", "BottomMargin"], [1, "fa-solid", "fa-link", 2, "color", "#6c757d"], [3, "close", "width", "height", "minWidth", "minHeight", "draggable", "resizable", "state", "title"], [3, "visibilityChange", "entity", "mode", "isVisible"]], template: function AIPromptFormComponentExtended_Template(rf, ctx) { if (rf & 1) {
2262
2273
  i0.ɵɵelementStart(0, "div", 2);
2263
- i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Template, 63, 35, "form", 3);
2264
- i0.ɵɵelementStart(2, "mj-ai-prompt-execution-dialog", 4);
2265
- i0.ɵɵtwoWayListener("isVisibleChange", function AIPromptFormComponentExtended_Template_mj_ai_prompt_execution_dialog_isVisibleChange_2_listener($event) { i0.ɵɵtwoWayBindingSet(ctx.showExecutionDialog, $event) || (ctx.showExecutionDialog = $event); return $event; });
2266
- i0.ɵɵelementEnd();
2267
- i0.ɵɵtemplate(3, AIPromptFormComponentExtended_Conditional_3_Template, 2, 12, "kendo-window", 5);
2274
+ i0.ɵɵtemplate(1, AIPromptFormComponentExtended_form_1_Template, 63, 35, "form", 3)(2, AIPromptFormComponentExtended_Conditional_2_Template, 2, 12, "kendo-window", 4);
2268
2275
  i0.ɵɵelementEnd();
2269
2276
  } if (rf & 2) {
2270
2277
  i0.ɵɵproperty("bottomMargin", 20)("rightMargin", 5);
2271
2278
  i0.ɵɵadvance();
2272
2279
  i0.ɵɵproperty("ngIf", ctx.record);
2273
2280
  i0.ɵɵadvance();
2274
- i0.ɵɵproperty("aiPrompt", ctx.record);
2275
- i0.ɵɵtwoWayProperty("isVisible", ctx.showExecutionDialog);
2276
- i0.ɵɵadvance();
2277
- i0.ɵɵconditional(ctx.showTestHarness ? 3 : -1);
2278
- } }, dependencies: [i3.NgIf, i4.ɵNgNoValidate, i4.NgControlStatus, i4.NgControlStatusGroup, i4.NgModel, i4.NgForm, i5.ExpansionPanelComponent, i5.ExpansionPanelTitleDirective, i6.WindowComponent, i7.TextAreaComponent, i7.TextBoxComponent, i7.NumericTextBoxComponent, i8.ItemTemplateDirective, i8.DropDownListComponent, i8.DropDownTreeComponent, i9.ButtonGroupComponent, i9.ButtonComponent, i10.UserViewGridComponent, i11.MJFormField, i12.FormToolbarComponent, i13.FillContainer, i14.CodeEditorComponent, i15.TemplateEditorComponent, i16.AIPromptExecutionDialogComponent, i17.AITestHarnessComponent, i3.DatePipe], styles: [".record-form-container[_ngcontent-%COMP%] {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n padding: 10px;\n}\n\n.custom-toolbar-actions[_ngcontent-%COMP%] {\n margin-left: auto;\n}\n\n.status-badge[_ngcontent-%COMP%] {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n font-weight: 500;\n letter-spacing: 0.02em;\n}\n\n.config-summary[_ngcontent-%COMP%] {\n position: sticky;\n top: 0;\n max-height: 600px;\n overflow-y: auto;\n}\n\n.config-item[_ngcontent-%COMP%] {\n padding: 8px 0;\n border-bottom: 1px solid #e9ecef;\n}\n\n.config-item[_ngcontent-%COMP%]:last-child {\n border-bottom: none;\n}\n\n.template-tab-content[_ngcontent-%COMP%] {\n background: #fff;\n}\n\n.template-header[_ngcontent-%COMP%] h5[_ngcontent-%COMP%] {\n font-size: 1.1em;\n}\n\n.loading-state[_ngcontent-%COMP%], \n.no-template-state[_ngcontent-%COMP%], \n.invalid-template-state[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n}\n\n.no-template-state[_ngcontent-%COMP%] i[_ngcontent-%COMP%], \n.invalid-template-state[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n opacity: 0.6;\n}\n\n.template-editor-container[_ngcontent-%COMP%] {\n background: #fff;\n border-radius: 6px;\n}\n\n\n\n@media (max-width: 1200px) {\n .record-form-container[_ngcontent-%COMP%] .mj-tab-body[_ngcontent-%COMP%] > div[_ngcontent-%COMP%] {\n grid-template-columns: 1fr !important;\n gap: 20px;\n }\n \n .config-summary[_ngcontent-%COMP%] {\n order: -1;\n position: static;\n max-height: none;\n }\n}\n\n\n\n@media (max-width: 768px) {\n .custom-toolbar-actions[_ngcontent-%COMP%] {\n flex-direction: column;\n gap: 4px !important;\n }\n \n .status-badge[_ngcontent-%COMP%] {\n align-self: flex-start;\n }\n}\n\n\n\n.record-form-container[_ngcontent-%COMP%] mj-form-section[_ngcontent-%COMP%] {\n padding: 16px;\n}\n\n\n\n.status-badge[_ngcontent-%COMP%], \n.config-item[_ngcontent-%COMP%], \n.template-header[_ngcontent-%COMP%] {\n transition: all 0.2s ease;\n}\n\n.config-item[_ngcontent-%COMP%]:hover {\n background-color: rgba(0,0,0,0.02);\n border-radius: 4px;\n margin: 0 -8px;\n padding: 8px;\n}\n\n\n\n.history-row[_ngcontent-%COMP%] {\n transition: background 0.2s;\n}\n\n.history-row[_ngcontent-%COMP%]:not(.even-row) {\n background: #f8f9fa;\n}\n\n.history-row.even-row[_ngcontent-%COMP%] {\n background: white;\n}\n\n.history-row[_ngcontent-%COMP%]:hover {\n background: #e9ecef !important;\n}"] }); }
2281
+ i0.ɵɵconditional(ctx.showTestHarness ? 2 : -1);
2282
+ } }, dependencies: [i3.NgIf, i4.ɵNgNoValidate, i4.NgControlStatus, i4.NgControlStatusGroup, i4.NgModel, i4.NgForm, i5.ExpansionPanelComponent, i5.ExpansionPanelTitleDirective, i6.WindowComponent, i7.TextAreaComponent, i7.TextBoxComponent, i7.NumericTextBoxComponent, i8.ItemTemplateDirective, i8.DropDownListComponent, i8.DropDownTreeComponent, i9.ButtonGroupComponent, i9.ButtonComponent, i10.UserViewGridComponent, i11.MJFormField, i12.FormToolbarComponent, i13.FillContainer, i14.CodeEditorComponent, i15.TemplateEditorComponent, i16.AITestHarnessComponent, i3.DatePipe], styles: [".record-form-container[_ngcontent-%COMP%] {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n padding: 10px;\n}\n\n.custom-toolbar-actions[_ngcontent-%COMP%] {\n margin-left: auto;\n}\n\n.status-badge[_ngcontent-%COMP%] {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n font-weight: 500;\n letter-spacing: 0.02em;\n}\n\n.config-summary[_ngcontent-%COMP%] {\n position: sticky;\n top: 0;\n max-height: 600px;\n overflow-y: auto;\n}\n\n.config-item[_ngcontent-%COMP%] {\n padding: 8px 0;\n border-bottom: 1px solid #e9ecef;\n}\n\n.config-item[_ngcontent-%COMP%]:last-child {\n border-bottom: none;\n}\n\n.template-tab-content[_ngcontent-%COMP%] {\n background: #fff;\n}\n\n.template-header[_ngcontent-%COMP%] h5[_ngcontent-%COMP%] {\n font-size: 1.1em;\n}\n\n.loading-state[_ngcontent-%COMP%], \n.no-template-state[_ngcontent-%COMP%], \n.invalid-template-state[_ngcontent-%COMP%] {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n}\n\n.no-template-state[_ngcontent-%COMP%] i[_ngcontent-%COMP%], \n.invalid-template-state[_ngcontent-%COMP%] i[_ngcontent-%COMP%] {\n opacity: 0.6;\n}\n\n.template-editor-container[_ngcontent-%COMP%] {\n background: #fff;\n border-radius: 6px;\n}\n\n\n\n@media (max-width: 1200px) {\n .record-form-container[_ngcontent-%COMP%] .mj-tab-body[_ngcontent-%COMP%] > div[_ngcontent-%COMP%] {\n grid-template-columns: 1fr !important;\n gap: 20px;\n }\n \n .config-summary[_ngcontent-%COMP%] {\n order: -1;\n position: static;\n max-height: none;\n }\n}\n\n\n\n@media (max-width: 768px) {\n .custom-toolbar-actions[_ngcontent-%COMP%] {\n flex-direction: column;\n gap: 4px !important;\n }\n \n .status-badge[_ngcontent-%COMP%] {\n align-self: flex-start;\n }\n}\n\n\n\n.record-form-container[_ngcontent-%COMP%] mj-form-section[_ngcontent-%COMP%] {\n padding: 16px;\n}\n\n\n\n.status-badge[_ngcontent-%COMP%], \n.config-item[_ngcontent-%COMP%], \n.template-header[_ngcontent-%COMP%] {\n transition: all 0.2s ease;\n}\n\n.config-item[_ngcontent-%COMP%]:hover {\n background-color: rgba(0,0,0,0.02);\n border-radius: 4px;\n margin: 0 -8px;\n padding: 8px;\n}\n\n\n\n.history-row[_ngcontent-%COMP%] {\n transition: background 0.2s;\n}\n\n.history-row[_ngcontent-%COMP%]:not(.even-row) {\n background: #f8f9fa;\n}\n\n.history-row.even-row[_ngcontent-%COMP%] {\n background: white;\n}\n\n.history-row[_ngcontent-%COMP%]:hover {\n background: #e9ecef !important;\n}"] }); }
2279
2283
  };
2280
2284
  AIPromptFormComponentExtended = __decorate([
2281
2285
  RegisterClass(BaseFormComponent, 'AI Prompts')
@@ -2283,7 +2287,7 @@ AIPromptFormComponentExtended = __decorate([
2283
2287
  export { AIPromptFormComponentExtended };
2284
2288
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(AIPromptFormComponentExtended, [{
2285
2289
  type: Component,
2286
- args: [{ selector: 'mj-ai-prompt-form', template: "<div class=\"record-form-container\" mjFillContainer [bottomMargin]=\"20\" [rightMargin]=\"5\">\n <form *ngIf=\"record\" class=\"record-form\" #form=\"ngForm\" mjFillContainer>\n <mj-form-toolbar [form]=\"this\"></mj-form-toolbar>\n\n <!-- Main Content Area - Template Editor and Configuration -->\n <div class=\"prompt-main-area\" style=\"display: flex; flex-direction: column; height: 100%; overflow-y: auto;\">\n \n <!-- Header Section -->\n <div class=\"prompt-header\" style=\"flex-shrink: 0; padding: 20px; background: #f8f9fa; border-bottom: 2px solid #e9ecef;\">\n <div style=\"display: flex; justify-content: space-between; align-items: flex-start; gap: 20px;\">\n \n <!-- Left: Prompt Info -->\n <div style=\"flex: 1; min-width: 0;\">\n <div style=\"display: flex; align-items: center; gap: 12px; margin-bottom: 8px;\">\n <i class=\"fa-solid fa-robot\" style=\"color: #6f42c1; font-size: 1.4em;\"></i>\n @if (EditMode) {\n <kendo-textbox [(ngModel)]=\"record.Name\" \n name=\"promptName\"\n placeholder=\"Enter prompt name...\"\n style=\"font-size: 1.2em; font-weight: 600; min-width: 300px; flex: 1;\">\n </kendo-textbox>\n } @else {\n <h4 style=\"margin: 0; color: #495057; font-weight: 600; flex: 1;\">{{ record.Name || 'Untitled AI Prompt' }}</h4>\n <span class=\"status-badge\" [style.background-color]=\"getStatusBadgeColor()\" \n style=\"color: white; padding: 4px 10px; border-radius: 12px; font-size: 0.75em; font-weight: 500;\">\n {{ record.Status }}\n </span>\n }\n </div>\n \n <!-- Status and Type Editors when in edit mode -->\n @if (EditMode) {\n <div style=\"display: flex; gap: 16px; margin-bottom: 12px; flex-wrap: wrap;\">\n <div>\n <label style=\"display: block; margin-bottom: 4px; font-weight: 600; color: #495057; font-size: 0.9em;\">Status</label>\n <kendo-dropdownlist [(ngModel)]=\"record.Status\"\n name=\"promptStatus\"\n [data]=\"[{text: 'Active', value: 'Active'}, {text: 'Pending', value: 'Pending'}, {text: 'Disabled', value: 'Disabled'}]\"\n textField=\"text\"\n valueField=\"value\"\n [valuePrimitive]=\"true\"\n style=\"width: 150px;\">\n </kendo-dropdownlist>\n </div>\n <div>\n <label style=\"display: block; margin-bottom: 4px; font-weight: 600; color: #495057; font-size: 0.9em;\">\n Type <span style=\"color: #dc3545;\">*</span>\n </label>\n @if (isLoadingPromptTypes) {\n <div style=\"padding: 8px; color: #6c757d; font-style: italic; width: 200px;\">\n <i class=\"fa-solid fa-spinner fa-spin\"></i> Loading types...\n </div>\n } @else {\n <kendo-dropdownlist [(ngModel)]=\"record.TypeID\"\n name=\"promptTypeID\"\n [data]=\"availablePromptTypes\"\n textField=\"Name\"\n valueField=\"ID\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select prompt type...\"\n style=\"width: 200px;\">\n </kendo-dropdownlist>\n }\n </div>\n </div>\n }\n \n @if (EditMode) {\n <kendo-textarea [(ngModel)]=\"record.Description\" \n name=\"promptDescription\"\n [rows]=\"2\"\n placeholder=\"Enter prompt description...\"\n style=\"width: 100%; max-width: 600px; margin-bottom: 12px;\">\n </kendo-textarea>\n } @else if (record.Description) {\n <p style=\"margin: 0 0 12px 0; color: #6c757d; font-size: 0.9em; line-height: 1.4;\">{{ record.Description }}</p>\n }\n \n <!-- Quick Config Row -->\n <div class=\"quick-config\" style=\"display: flex; align-items: center; gap: 16px; flex-wrap: wrap;\">\n @if (record.TypeID) {\n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-tag\" style=\"color: #6c757d;\"></i>\n <span style=\"color: #6c757d;\">Type:</span>\n <span style=\"color: #495057; font-weight: 500;\">{{ getPromptTypeDisplayName(record.TypeID) }}</span>\n </div>\n }\n \n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-layer-group\" style=\"color: #6c757d;\"></i>\n <span style=\"color: #6c757d;\">Parallelization:</span>\n <span style=\"color: #495057; font-weight: 500;\">{{ getParallelizationModeDisplay() }}</span>\n </div>\n \n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-code\" style=\"color: #6c757d;\"></i>\n <span style=\"color: #6c757d;\">Output:</span>\n <span [style.color]=\"getValidationColor()\" style=\"font-weight: 500;\">{{ getOutputTypeDisplay() }}</span>\n </div>\n \n @if (record.EnableCaching) {\n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-database\" style=\"color: #28a745;\"></i>\n <span style=\"color: #28a745; font-weight: 500;\">Caching Enabled</span>\n </div>\n }\n </div>\n </div>\n \n <!-- Right: Action Buttons -->\n <div class=\"action-buttons\" style=\"display: flex; flex-direction: column; gap: 8px; align-items: flex-end;\">\n <div style=\"display: flex; gap: 8px;\">\n @if (record.ID) {\n <kendo-button themeColor=\"primary\" size=\"large\"\n (click)=\"openTestHarness()\"\n title=\"Run AI Prompt Test Harness\">\n <i class=\"fa-solid fa-play\"></i> Run\n </kendo-button>\n }\n </div>\n \n @if (!canExecute && record.ID) {\n <div style=\"font-size: 0.75em; color: #dc3545; text-align: right; max-width: 200px;\">\n @if (record.Status !== 'Active') {\n \u2022 Prompt must be Active<br>\n }\n @if (!record.TemplateID) {\n \u2022 Template is required<br>\n }\n @if (!template && record.TemplateID) {\n \u2022 Template not found<br>\n }\n </div>\n }\n </div>\n </div>\n </div>\n\n <!-- Configuration Sections with Expansion Panels -->\n <div class=\"configuration-sections\" style=\"flex: 1; background: white; border-top: 2px solid #e9ecef; padding: 16px; min-height: 0;\">\n <!-- Template Editor Section -->\n <kendo-expansionpanel \n [expanded]=\"true\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-code\" style=\"color: #6c757d;\"></i>\n Template Editor\n @if (template) {\n <span style=\"color: #6c757d; font-size: 0.9em; font-weight: normal;\">\u2022 {{ template.Name }}</span>\n }\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div class=\"template-section\" style=\"display: flex; flex-direction: column; min-height: 400px; padding: 8px;\">\n @if (isLoadingTemplate) {\n <div class=\"loading-state\" style=\"flex: 1; display: flex; align-items: center; justify-content: center; color: #6c757d;\">\n <i class=\"fa-solid fa-spinner fa-spin\" style=\"font-size: 24px; margin-right: 12px;\"></i>\n Loading template...\n </div>\n } @else if (!record.TemplateID) {\n <div class=\"no-template-state\" style=\"flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px; color: #6c757d;\">\n <i class=\"fa-solid fa-code\" style=\"font-size: 64px; margin-bottom: 20px; opacity: 0.3;\"></i>\n <h5 style=\"margin-bottom: 12px; color: #495057;\">No Template Associated</h5>\n <p style=\"margin-bottom: 24px; text-align: center; max-width: 400px;\">\n This AI prompt needs a template to define its structure and parameters. \n Create a new template or link to an existing one.\n </p>\n <div style=\"display: flex; gap: 12px;\">\n <kendo-button themeColor=\"primary\" (click)=\"createNewTemplate()\">\n <i class=\"fa-solid fa-plus\"></i> Create New Template\n </kendo-button>\n <kendo-button fillMode=\"outline\" (click)=\"linkExistingTemplate()\">\n <i class=\"fa-solid fa-link\"></i> Link Existing Template\n </kendo-button>\n </div>\n </div>\n } @else if (templateNotFoundInDatabase) {\n <div class=\"invalid-template-state\" style=\"flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px; color: #dc3545;\">\n <i class=\"fa-solid fa-exclamation-triangle\" style=\"font-size: 64px; margin-bottom: 20px; opacity: 0.7;\"></i>\n <h5 style=\"margin-bottom: 12px;\">Template Not Found</h5>\n <p style=\"margin-bottom: 24px; text-align: center; max-width: 400px;\">\n The referenced template could not be loaded. It may have been deleted or moved.\n </p>\n <div style=\"display: flex; gap: 12px;\">\n <kendo-button fillMode=\"outline\" (click)=\"loadTemplate()\">\n <i class=\"fa-solid fa-refresh\"></i> Retry Loading\n </kendo-button>\n <kendo-button themeColor=\"primary\" (click)=\"createNewTemplate()\">\n <i class=\"fa-solid fa-plus\"></i> Create New Template\n </kendo-button>\n </div>\n </div>\n } @else {\n <!-- Active Template Editor -->\n <div class=\"template-editor-container\" style=\"flex: 1; display: flex; flex-direction: column; min-height: 350px;\">\n <!-- Template Editor -->\n <div style=\"flex: 1; background: white; border-radius: 6px; border: 1px solid #e9ecef;\">\n <mj-template-editor \n #templateEditor\n [template]=\"template\"\n [config]=\"templateEditorConfig\"\n (contentChange)=\"onTemplateContentChange($event)\"\n (runTemplate)=\"onTemplateRun($event)\"\n style=\"display: block; min-height: 300px;\">\n </mj-template-editor>\n </div>\n </div>\n }\n </div>\n </kendo-expansionpanel> \n\n <!-- Model Configuration Expansion Panel -->\n @if (record.IsSaved) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-microchip\" style=\"color: #6c757d;\"></i>\n Models\n @if (promptModels.length > 0) {\n <span class=\"badge\" style=\"background: #17a2b8; color: white; padding: 2px 6px; border-radius: 10px; font-size: 0.7em;\">\n {{ promptModels.length }}\n </span>\n }\n <span style=\"color: #6c757d; font-size: 0.8em; font-weight: normal; margin-left: 8px;\">\n <i class=\"fa-solid fa-info-circle\" title=\"Models are tried in order from top to bottom. The first available model will be used.\"></i>\n Priority order (first available model will be used)\n </span>\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <!-- Model Management Interface -->\n <div class=\"model-management\" style=\"border: 1px solid #dee2e6; border-radius: 6px; background: #f8f9fa;\">\n @if (isLoadingModels) {\n <div class=\"loading-state\" style=\"padding: 20px; text-align: center; color: #6c757d;\">\n <i class=\"fa-solid fa-spinner fa-spin\"></i> Loading models...\n </div>\n } @else {\n @if (promptModels.length === 0) {\n <div class=\"empty-state\" style=\"padding: 20px; text-align: center; color: #6c757d;\">\n <i class=\"fa-solid fa-info-circle\"></i> No models configured\n @if (EditMode) {\n <div style=\"margin-top: 10px;\">\n <kendo-button fillMode=\"outline\" themeColor=\"primary\" size=\"small\"\n (click)=\"addNewModel()\">\n <i class=\"fa-solid fa-plus\"></i> Add Model\n </kendo-button>\n </div>\n }\n </div>\n } @else {\n <!-- Priority explanation for multiple models -->\n @if (promptModels.length > 1) {\n <div style=\"padding: 12px 16px; background: #e3f2fd; border-bottom: 1px solid #bbdefb; color: #1565c0; font-size: 0.85em;\">\n <i class=\"fa-solid fa-info-circle\" style=\"margin-right: 6px;\"></i>\n Models are tried in priority order (1, 2, 3...). The first available model that meets requirements will be used for execution.\n </div>\n }\n <!-- Column Headers -->\n <div class=\"model-header\" style=\"display: grid; grid-template-columns: 40px 2fr 1fr 1fr 60px; gap: 12px; padding: 12px 16px; background: #e9ecef; font-weight: 600; font-size: 0.85em; color: #495057; border-bottom: 1px solid #dee2e6;\">\n <div title=\"Priority order - models are tried from top to bottom\">\n <i class=\"fa-solid fa-sort\" style=\"color: #6c757d;\"></i>\n </div>\n <div>AI Model <span style=\"color: #dc3545;\">*</span></div>\n <div>Vendor</div>\n <div>Created</div>\n <div>Actions</div>\n </div>\n \n @for (model of promptModels; track model.ID || $index; let i = $index) {\n <div class=\"model-row\" \n [draggable]=\"EditMode\"\n (dragstart)=\"onDragStart($event, i)\"\n (dragover)=\"onDragOver($event)\"\n (drop)=\"onDrop($event, i)\"\n (dragend)=\"onDragEnd($event)\"\n [style.background]=\"!model.ModelID ? '#fff3cd' : (draggedIndex === i ? '#e3f2fd' : 'white')\"\n [style.border-left]=\"!model.ModelID ? '3px solid #ffc107' : 'none'\"\n [style.opacity]=\"draggedIndex === i ? '0.5' : '1'\"\n style=\"display: grid; grid-template-columns: 40px 2fr 1fr 1fr 60px; gap: 12px; padding: 12px 16px; border-bottom: 1px solid #e9ecef; align-items: start; transition: background 0.2s, opacity 0.2s;\">\n \n <!-- Drag Handle / Priority -->\n <div class=\"drag-handle\" style=\"display: flex; flex-direction: column; align-items: center; justify-content: center; color: #6c757d;\">\n @if (EditMode) {\n <i class=\"fa-solid fa-grip-vertical\" title=\"Drag to reorder priority\" style=\"cursor: move;\"></i>\n <span style=\"font-size: 0.7em; margin-top: 2px;\">#{{ i + 1 }}</span>\n } @else {\n <span style=\"font-size: 0.9em; font-weight: 600;\" title=\"Priority {{ i + 1 }} - Lower numbers are tried first\">#{{ i + 1 }}</span>\n }\n </div>\n \n <!-- Model Selection -->\n <div class=\"model-select\">\n @if (EditMode) {\n <kendo-dropdownlist [(ngModel)]=\"model.ModelID\"\n [name]=\"'modelId_' + i\"\n [data]=\"availableModels\"\n textField=\"Name\"\n valueField=\"ID\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select a model...\"\n (valueChange)=\"onModelChange($event, i)\"\n style=\"width: 100%;\">\n </kendo-dropdownlist>\n } @else {\n <span style=\"font-weight: 500;\">{{ getModelDisplayName(model.ModelID) }}</span>\n }\n </div>\n \n <!-- Vendor -->\n <div class=\"model-vendor\">\n @if (EditMode) {\n @if (model.ModelID) {\n @if (shouldShowVendorDropdown(model.ModelID)) {\n <kendo-dropdownlist [(ngModel)]=\"model.VendorID\"\n [name]=\"'vendorId_' + i\"\n [data]=\"getVendorsForModelSync(model.ModelID)\"\n textField=\"Name\"\n valueField=\"ID\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select vendor...\"\n style=\"width: 100%;\">\n <ng-template kendoDropDownListItemTemplate let-dataItem>\n <span [style.color]=\"getVendorStatusColor(model.ModelID, dataItem.ID)\">\n {{ dataItem.Name }}\n @if (getModelVendorStatus(model.ModelID, dataItem.ID) !== 'Active') {\n <span style=\"font-size: 0.8em; margin-left: 4px;\">({{ getModelVendorStatus(model.ModelID, dataItem.ID) }})</span>\n }\n </span>\n </ng-template>\n </kendo-dropdownlist>\n } @else {\n <!-- Single vendor - just show the name -->\n @if (getVendorsForModelSync(model.ModelID).length === 1) {\n <span [style.color]=\"getVendorStatusColor(model.ModelID, getVendorsForModelSync(model.ModelID)[0].ID)\" style=\"font-size: 0.9em; font-weight: 500;\">\n {{ getVendorsForModelSync(model.ModelID)[0].Name }}\n @if (getModelVendorStatus(model.ModelID, getVendorsForModelSync(model.ModelID)[0].ID) !== 'Active') {\n <span style=\"font-size: 0.8em; margin-left: 4px;\">({{ getModelVendorStatus(model.ModelID, getVendorsForModelSync(model.ModelID)[0].ID) }})</span>\n }\n </span>\n } @else {\n <span style=\"color: #6c757d; font-style: italic; font-size: 0.9em;\">No vendors available</span>\n }\n }\n } @else {\n <span style=\"color: #6c757d; font-style: italic; font-size: 0.9em;\">Select model first</span>\n }\n } @else {\n @if (model.VendorID && model.ModelID) {\n <span [style.color]=\"getVendorStatusColor(model.ModelID, model.VendorID)\" style=\"font-size: 0.9em;\">\n {{ getVendorDisplayName(model.VendorID) }}\n @if (getModelVendorStatus(model.ModelID, model.VendorID) !== 'Active') {\n <span style=\"font-size: 0.8em; margin-left: 4px;\">({{ getModelVendorStatus(model.ModelID, model.VendorID) }})</span>\n }\n </span>\n } @else {\n <span style=\"color: #6c757d; font-size: 0.9em;\">-</span>\n }\n }\n </div>\n \n \n <!-- Created Date -->\n <div class=\"model-created\">\n @if (model.ID) {\n <span style=\"color: #6c757d; font-size: 0.8em;\">{{ model.__mj_CreatedAt | date:'short' }}</span>\n } @else {\n <span style=\"color: #28a745; font-size: 0.8em; font-style: italic;\">New</span>\n }\n </div>\n \n <!-- Actions -->\n <div class=\"model-actions\" style=\"display: flex; gap: 2px; flex-direction: column;\">\n @if (EditMode) {\n <div style=\"display: flex; gap: 2px; margin-bottom: 4px;\">\n <kendo-button fillMode=\"flat\" size=\"small\"\n (click)=\"moveModelUp(i)\"\n [disabled]=\"i === 0\"\n title=\"Move up\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </kendo-button>\n <kendo-button fillMode=\"flat\" size=\"small\"\n (click)=\"moveModelDown(i)\"\n [disabled]=\"i === promptModels.length - 1\"\n title=\"Move down\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </kendo-button>\n </div>\n <kendo-button fillMode=\"flat\" themeColor=\"error\" size=\"small\"\n (click)=\"removePromptModel(i)\"\n title=\"Remove model\">\n <i class=\"fa-solid fa-times\"></i>\n </kendo-button>\n }\n </div>\n </div>\n \n <!-- Second row with additional details -->\n <div style=\"display: grid; grid-template-columns: 40px 1fr; gap: 12px; padding: 8px 16px; border-bottom: 1px solid #e9ecef; background: #f8f9fa; font-size: 0.85em; color: #6c757d;\">\n <div></div>\n <div>\n <!-- Basic model details -->\n <div style=\"display: flex; gap: 16px; flex-wrap: wrap; align-items: center; margin-bottom: 8px;\">\n @if (model.Status) {\n <span><strong>Status:</strong> {{ model.Status }}</span>\n }\n @if (model.ConfigurationID) {\n <span><strong>Configuration:</strong> {{ model.ConfigurationID }}</span>\n }\n </div>\n \n <!-- Parallel execution fields when prompt is ModelSpecific -->\n @if (record.ParallelizationMode === 'ModelSpecific') {\n <div style=\"padding: 8px; background: #fff; border: 1px solid #dee2e6; border-radius: 4px; margin-top: 8px;\">\n <div style=\"margin-bottom: 6px; font-weight: 600; color: #495057; font-size: 0.9em;\">\n <i class=\"fa-solid fa-layer-group\"></i> Model-Specific Parallel Execution\n </div>\n \n @if (EditMode) {\n <div style=\"display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; align-items: center;\">\n <!-- Parallel Mode -->\n <div>\n <label style=\"display: block; margin-bottom: 2px; font-size: 0.8em; font-weight: 600; color: #495057;\">Parallel Mode</label>\n <kendo-dropdownlist [(ngModel)]=\"model.ParallelizationMode\"\n [name]=\"'parallelMode_' + i\"\n [data]=\"[{text: 'None', value: 'None'}, {text: 'Static Count', value: 'StaticCount'}, {text: 'Config Param', value: 'ConfigParam'}]\"\n textField=\"text\"\n valueField=\"value\"\n [valuePrimitive]=\"true\"\n placeholder=\"Select mode...\"\n style=\"width: 100%; font-size: 0.85em;\">\n </kendo-dropdownlist>\n </div>\n \n <!-- Parallel Count (when StaticCount) -->\n @if (model.ParallelizationMode === 'StaticCount') {\n <div>\n <label style=\"display: block; margin-bottom: 2px; font-size: 0.8em; font-weight: 600; color: #495057;\">Parallel Count</label>\n <kendo-numerictextbox [(ngModel)]=\"model.ParallelCount\"\n [name]=\"'parallelCount_' + i\"\n [min]=\"1\"\n [step]=\"1\"\n [format]=\"'n0'\"\n placeholder=\"Count...\"\n style=\"width: 100%; font-size: 0.85em;\">\n </kendo-numerictextbox>\n </div>\n }\n \n <!-- Config Param (when ConfigParam) -->\n @if (model.ParallelizationMode === 'ConfigParam') {\n <div>\n <label style=\"display: block; margin-bottom: 2px; font-size: 0.8em; font-weight: 600; color: #495057;\">Config Parameter</label>\n <kendo-textbox [(ngModel)]=\"model.ParallelConfigParam\"\n [name]=\"'parallelConfigParam_' + i\"\n placeholder=\"Parameter name...\"\n style=\"width: 100%; font-size: 0.85em;\">\n </kendo-textbox>\n </div>\n }\n </div>\n } @else {\n <!-- Read-only display -->\n <div style=\"display: flex; gap: 16px; flex-wrap: wrap; align-items: center;\">\n @if (model.ParallelizationMode) {\n <span><strong>Parallel Mode:</strong> {{ model.ParallelizationMode }}</span>\n }\n @if (model.ParallelCount) {\n <span><strong>Parallel Count:</strong> {{ model.ParallelCount }}</span>\n }\n @if (model.ParallelConfigParam) {\n <span><strong>Config Param:</strong> {{ model.ParallelConfigParam }}</span>\n }\n </div>\n }\n </div>\n }\n </div>\n </div>\n }\n \n @if (EditMode) {\n <div class=\"add-model-row\" style=\"padding: 12px 16px; text-align: center; background: #f8f9fa; border-top: 1px solid #dee2e6;\">\n <kendo-button fillMode=\"outline\" themeColor=\"success\" size=\"small\"\n (click)=\"addNewModel()\">\n <i class=\"fa-solid fa-plus\"></i> Add Model\n </kendo-button>\n </div>\n }\n }\n }\n </div>\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Advanced Configuration Expansion Panel -->\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-cogs\" style=\"color: #6c757d;\"></i>\n Advanced Configuration\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <div style=\"display: grid; grid-template-columns: 1fr 1fr; gap: 20px;\">\n \n <!-- Left Column -->\n <div>\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ParallelizationMode\"\n Type=\"dropdownlist\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n @if (showParallelCount) {\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ParallelCount\"\n Type=\"numerictextbox\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n }\n \n @if (showParallelConfigParam) {\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ParallelConfigParam\"\n Type=\"textbox\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n }\n \n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"OutputType\"\n Type=\"dropdownlist\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n </div>\n \n <!-- Right Column -->\n <div>\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ValidationBehavior\"\n Type=\"dropdownlist\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"EnableCaching\"\n Type=\"checkbox\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n <!-- Result Selector Prompt with Tree Selector -->\n <div style=\"margin-bottom: 16px;\">\n <label style=\"display: block; margin-bottom: 4px; font-weight: 600; color: #495057; font-size: 0.9em;\">\n Result Selector Prompt\n </label>\n @if (EditMode) {\n @if (isLoadingResultSelectorData) {\n <div style=\"padding: 8px; color: #6c757d; font-style: italic;\">\n <i class=\"fa-solid fa-spinner fa-spin\"></i> Loading prompts...\n </div>\n } @else {\n <kendo-dropdowntree \n [(ngModel)]=\"record.ResultSelectorPromptID\"\n name=\"resultSelectorPromptID\"\n [data]=\"resultSelectorTreeData\"\n textField=\"text\"\n valueField=\"value\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select a result selector prompt...\"\n style=\"width: 100%;\"\n (valueChange)=\"onResultSelectorChange($event)\">\n </kendo-dropdowntree>\n }\n } @else {\n <span style=\"color: #495057;\">{{ getPromptDisplayName(record.ResultSelectorPromptID || '') || 'None selected' }}</span>\n }\n </div>\n </div>\n </div>\n </div>\n </kendo-expansionpanel>\n\n <!-- Output Example Expansion Panel (when OutputType = object) -->\n @if (showOutputExample) {\n <kendo-expansionpanel \n [expanded]=\"true\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-code\" style=\"color: #6c757d;\"></i>\n Output Example (JSON)\n <span style=\"color: #dc3545; font-size: 0.8em; font-weight: normal;\">\u2022 Required for object output type</span>\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px;\">\n @if (EditMode) {\n <mj-code-editor \n [(ngModel)]=\"record.OutputExample\"\n name=\"outputExample\"\n language=\"json\"\n placeholder=\"Enter JSON example structure...\"\n style=\"width: 100%; height: 200px; border: 1px solid #dee2e6; border-radius: 4px;\">\n </mj-code-editor>\n <div style=\"margin-top: 8px; color: #6c757d; font-size: 0.85em;\">\n <i class=\"fa-solid fa-info-circle\"></i> Provide a JSON example that defines the expected structure for object output validation.\n </div>\n } @else if (record.OutputExample) {\n <div style=\"background: #f8f9fa; border: 1px solid #dee2e6; border-radius: 4px; padding: 12px; font-family: 'Courier New', monospace; font-size: 0.9em; white-space: pre-wrap; overflow: auto; max-height: 250px;\">{{ record.OutputExample }}</div>\n } @else {\n <div style=\"background: #fff3cd; border: 1px solid #ffeaa7; border-radius: 4px; padding: 12px; color: #856404; text-align: center;\">\n <i class=\"fa-solid fa-exclamation-triangle\"></i> Output example is required when output type is 'object'\n </div>\n }\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Execution History Expansion Panel -->\n @if (record.IsSaved) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-history\" style=\"color: #6c757d;\"></i>\n Execution History\n @if (executionHistory.length > 0) {\n <span style=\"color: #6c757d; font-weight: normal;\">({{ executionHistory.length }})</span>\n }\n </span>\n </ng-template>\n \n <!-- Custom Execution History Viewer -->\n <div style=\"padding: 16px;\">\n @if (isLoadingHistory) {\n <div style=\"text-align: center; padding: 40px; color: #6c757d;\">\n <i class=\"fa-solid fa-spinner fa-spin\" style=\"font-size: 2em; margin-bottom: 12px;\"></i>\n <p>Loading execution history...</p>\n </div>\n } @else if (executionHistory.length === 0) {\n <div style=\"text-align: center; padding: 40px; color: #6c757d;\">\n <i class=\"fa-solid fa-history\" style=\"font-size: 3em; margin-bottom: 12px; opacity: 0.3;\"></i>\n <p>No execution history yet</p>\n <p style=\"font-size: 0.9em;\">Run this prompt to see execution history here</p>\n </div>\n } @else {\n <!-- Sort Controls -->\n <div style=\"display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px;\">\n <div style=\"color: #6c757d; font-size: 0.9em;\">\n Showing {{ executionHistory.length }} executions\n </div>\n <div style=\"display: flex; gap: 8px; align-items: center;\">\n <span style=\"color: #6c757d; font-size: 0.85em;\">Sort by:</span>\n <kendo-buttongroup selection=\"single\">\n <button kendoButton \n [selected]=\"historySortField === 'runAt'\"\n (click)=\"changeHistorySort('runAt')\"\n size=\"small\">\n Date\n @if (historySortField === 'runAt') {\n <i [class]=\"'fa-solid fa-sort-' + (historySortDirection === 'asc' ? 'up' : 'down')\" \n style=\"margin-left: 4px; font-size: 0.8em;\"></i>\n }\n </button>\n <button kendoButton \n [selected]=\"historySortField === 'executionTime'\"\n (click)=\"changeHistorySort('executionTime')\"\n size=\"small\">\n Duration\n @if (historySortField === 'executionTime') {\n <i [class]=\"'fa-solid fa-sort-' + (historySortDirection === 'asc' ? 'up' : 'down')\" \n style=\"margin-left: 4px; font-size: 0.8em;\"></i>\n }\n </button>\n <button kendoButton \n [selected]=\"historySortField === 'tokens'\"\n (click)=\"changeHistorySort('tokens')\"\n size=\"small\">\n Tokens\n @if (historySortField === 'tokens') {\n <i [class]=\"'fa-solid fa-sort-' + (historySortDirection === 'asc' ? 'up' : 'down')\" \n style=\"margin-left: 4px; font-size: 0.8em;\"></i>\n }\n </button>\n <button kendoButton \n [selected]=\"historySortField === 'cost'\"\n (click)=\"changeHistorySort('cost')\"\n size=\"small\">\n Cost\n @if (historySortField === 'cost') {\n <i [class]=\"'fa-solid fa-sort-' + (historySortDirection === 'asc' ? 'up' : 'down')\" \n style=\"margin-left: 4px; font-size: 0.8em;\"></i>\n }\n </button>\n </kendo-buttongroup>\n </div>\n </div>\n \n <!-- Execution History Table -->\n <div style=\"border: 1px solid #e9ecef; border-radius: 8px; overflow: hidden;\">\n <table style=\"width: 100%; border-collapse: collapse;\">\n <thead>\n <tr style=\"background: #f8f9fa; border-bottom: 2px solid #e9ecef;\">\n <th style=\"padding: 12px; text-align: left; font-weight: 600; color: #495057;\">Status</th>\n <th style=\"padding: 12px; text-align: left; font-weight: 600; color: #495057;\">Date & Time</th>\n <th style=\"padding: 12px; text-align: left; font-weight: 600; color: #495057;\">Model</th>\n <th style=\"padding: 12px; text-align: left; font-weight: 600; color: #495057;\">Duration</th>\n <th style=\"padding: 12px; text-align: right; font-weight: 600; color: #495057;\">Tokens</th>\n <th style=\"padding: 12px; text-align: right; font-weight: 600; color: #495057;\">Cost</th>\n <th style=\"padding: 12px; text-align: center; font-weight: 600; color: #495057;\">Type</th>\n <th style=\"padding: 12px; text-align: center; font-weight: 600; color: #495057;\">Actions</th>\n </tr>\n </thead>\n <tbody>\n @for (run of executionHistory; track run.ID; let i = $index) {\n <tr class=\"history-row\"\n [class.even-row]=\"i % 2 === 0\"\n style=\"border-bottom: 1px solid #f1f3f5;\">\n <td style=\"padding: 12px;\">\n <span style=\"display: flex; align-items: center; gap: 6px;\">\n <i [class]=\"'fa-solid ' + getExecutionStatusIcon(run.Success)\" \n [style.color]=\"getExecutionStatusColor(run.Success)\"></i>\n <span [style.color]=\"getExecutionStatusColor(run.Success)\" style=\"font-weight: 500;\">\n {{ run.Success === true ? 'Success' : run.Success === false ? 'Failed' : 'Running' }}\n </span>\n </span>\n </td>\n <td style=\"padding: 12px; color: #495057;\">\n {{ run.RunAt | date:'short' }}\n </td>\n <td style=\"padding: 12px; color: #495057;\">\n <span style=\"display: flex; align-items: center; gap: 6px;\">\n <i class=\"fa-solid fa-microchip\" style=\"color: #6c757d;\"></i>\n {{ run.Model || 'Unknown' }}\n </span>\n </td>\n <td style=\"padding: 12px; color: #495057;\">\n {{ formatDuration(run.ExecutionTimeMS) }}\n </td>\n <td style=\"padding: 12px; text-align: right; color: #495057;\">\n {{ formatTokens(run.TokensUsed) }}\n </td>\n <td style=\"padding: 12px; text-align: right; color: #495057;\">\n {{ formatCost(run.TotalCost || run.Cost) }}\n </td>\n <td style=\"padding: 12px; text-align: center;\">\n @if (run.RunType) {\n <span style=\"padding: 4px 8px; border-radius: 12px; background: #e9ecef; \n color: #495057; font-size: 0.85em; font-weight: 500;\">\n {{ run.RunType }}\n </span>\n }\n </td>\n <td style=\"padding: 12px; text-align: center;\">\n <kendo-button \n fillMode=\"flat\"\n size=\"small\"\n (click)=\"navigateToPromptRun(run.ID)\"\n title=\"View details\">\n <i class=\"fa-solid fa-external-link\"></i>\n </kendo-button>\n </td>\n </tr>\n }\n </tbody>\n </table>\n </div>\n }\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Cache Expansion Panel -->\n @if (record.IsSaved && record.EnableCaching) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-database\" style=\"color: #6c757d;\"></i>\n Result Cache\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <mj-user-view-grid \n [Params]=\"BuildRelationshipViewParamsByEntityName('AI Result Cache','AIPromptID')\" \n [NewRecordValues]=\"NewRecordValues('AI Result Cache')\"\n [AllowLoad]=\"true\"\n [EditMode]=\"GridEditMode()\" \n [BottomMargin]=\"0\"\n style=\"height: 300px;\">\n </mj-user-view-grid>\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Related Items Expansion Panel -->\n @if (record.IsSaved) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-link\" style=\"color: #6c757d;\"></i>\n Related Items\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <div style=\"display: grid; grid-template-columns: 1fr 1fr; gap: 20px;\">\n <!-- AI Agents -->\n <div>\n <h6 style=\"margin: 0 0 12px 0; color: #495057;\">AI Agents Using This Prompt</h6>\n <mj-user-view-grid \n [Params]=\"BuildRelationshipViewParamsByEntityName('MJ: AI Agent Prompts','PromptID')\" \n [NewRecordValues]=\"NewRecordValues('MJ: AI Agent Prompts')\"\n [AllowLoad]=\"true\"\n [EditMode]=\"GridEditMode()\" \n [BottomMargin]=\"0\"\n style=\"height: 200px;\">\n </mj-user-view-grid>\n </div>\n \n <!-- Result Selector References -->\n <div>\n <h6 style=\"margin: 0 0 12px 0; color: #495057;\">Prompts Using This as Result Selector</h6>\n <mj-user-view-grid \n [Params]=\"BuildRelationshipViewParamsByEntityName('AI Prompts','ResultSelectorPromptID')\" \n [NewRecordValues]=\"NewRecordValues('AI Prompts')\"\n [AllowLoad]=\"true\"\n [EditMode]=\"GridEditMode()\" \n [BottomMargin]=\"0\"\n style=\"height: 200px;\">\n </mj-user-view-grid>\n </div>\n </div>\n </div>\n </kendo-expansionpanel>\n }\n </div>\n </div>\n </form>\n\n <!-- AI Prompt Execution Dialog -->\n <mj-ai-prompt-execution-dialog\n [aiPrompt]=\"record\"\n [(isVisible)]=\"showExecutionDialog\">\n </mj-ai-prompt-execution-dialog>\n \n <!-- AI Prompt Test Harness -->\n @if (showTestHarness) {\n <kendo-window \n [width]=\"1200\" \n [height]=\"800\" \n [minWidth]=\"800\"\n [minHeight]=\"600\"\n [draggable]=\"true\"\n [resizable]=\"true\"\n [state]=\"'default'\"\n (close)=\"onTestHarnessVisibilityChanged(false)\"\n title=\"Run AI Prompt - {{ record.Name || 'Untitled' }}\">\n <mj-ai-test-harness\n [entity]=\"record\"\n [mode]=\"'prompt'\"\n [isVisible]=\"showTestHarness\"\n (visibilityChange)=\"onTestHarnessVisibilityChanged($event)\">\n </mj-ai-test-harness>\n </kendo-window>\n }\n</div>", styles: [".record-form-container {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n padding: 10px;\n}\n\n.custom-toolbar-actions {\n margin-left: auto;\n}\n\n.status-badge {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n font-weight: 500;\n letter-spacing: 0.02em;\n}\n\n.config-summary {\n position: sticky;\n top: 0;\n max-height: 600px;\n overflow-y: auto;\n}\n\n.config-item {\n padding: 8px 0;\n border-bottom: 1px solid #e9ecef;\n}\n\n.config-item:last-child {\n border-bottom: none;\n}\n\n.template-tab-content {\n background: #fff;\n}\n\n.template-header h5 {\n font-size: 1.1em;\n}\n\n.loading-state,\n.no-template-state,\n.invalid-template-state {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n}\n\n.no-template-state i,\n.invalid-template-state i {\n opacity: 0.6;\n}\n\n.template-editor-container {\n background: #fff;\n border-radius: 6px;\n}\n\n/* Grid layout adjustments */\n@media (max-width: 1200px) {\n .record-form-container .mj-tab-body > div {\n grid-template-columns: 1fr !important;\n gap: 20px;\n }\n \n .config-summary {\n order: -1;\n position: static;\n max-height: none;\n }\n}\n\n/* Responsive toolbar */\n@media (max-width: 768px) {\n .custom-toolbar-actions {\n flex-direction: column;\n gap: 4px !important;\n }\n \n .status-badge {\n align-self: flex-start;\n }\n}\n\n/* Ensure proper spacing in form sections */\n.record-form-container mj-form-section {\n padding: 16px;\n}\n\n/* Smooth transitions for better UX */\n.status-badge,\n.config-item,\n.template-header {\n transition: all 0.2s ease;\n}\n\n.config-item:hover {\n background-color: rgba(0,0,0,0.02);\n border-radius: 4px;\n margin: 0 -8px;\n padding: 8px;\n}\n\n/* Execution History Table Styles */\n.history-row {\n transition: background 0.2s;\n}\n\n.history-row:not(.even-row) {\n background: #f8f9fa;\n}\n\n.history-row.even-row {\n background: white;\n}\n\n.history-row:hover {\n background: #e9ecef !important;\n}"] }]
2290
+ args: [{ selector: 'mj-ai-prompt-form', template: "<div class=\"record-form-container\" mjFillContainer [bottomMargin]=\"20\" [rightMargin]=\"5\">\n <form *ngIf=\"record\" class=\"record-form\" #form=\"ngForm\" mjFillContainer>\n <mj-form-toolbar [form]=\"this\"></mj-form-toolbar>\n\n <!-- Main Content Area - Template Editor and Configuration -->\n <div class=\"prompt-main-area\" style=\"display: flex; flex-direction: column; height: 100%; overflow-y: auto;\">\n \n <!-- Header Section -->\n <div class=\"prompt-header\" style=\"flex-shrink: 0; padding: 20px; background: #f8f9fa; border-bottom: 2px solid #e9ecef;\">\n <div style=\"display: flex; justify-content: space-between; align-items: flex-start; gap: 20px;\">\n \n <!-- Left: Prompt Info -->\n <div style=\"flex: 1; min-width: 0;\">\n <div style=\"display: flex; align-items: center; gap: 12px; margin-bottom: 8px;\">\n <i class=\"fa-solid fa-robot\" style=\"color: #6f42c1; font-size: 1.4em;\"></i>\n @if (EditMode) {\n <kendo-textbox [(ngModel)]=\"record.Name\" \n name=\"promptName\"\n placeholder=\"Enter prompt name...\"\n style=\"font-size: 1.2em; font-weight: 600; min-width: 300px; flex: 1;\">\n </kendo-textbox>\n } @else {\n <h4 style=\"margin: 0; color: #495057; font-weight: 600; flex: 1;\">{{ record.Name || 'Untitled AI Prompt' }}</h4>\n <span class=\"status-badge\" [style.background-color]=\"getStatusBadgeColor()\" \n style=\"color: white; padding: 4px 10px; border-radius: 12px; font-size: 0.75em; font-weight: 500;\">\n {{ record.Status }}\n </span>\n }\n </div>\n \n <!-- Status and Type Editors when in edit mode -->\n @if (EditMode) {\n <div style=\"display: flex; gap: 16px; margin-bottom: 12px; flex-wrap: wrap;\">\n <div>\n <label style=\"display: block; margin-bottom: 4px; font-weight: 600; color: #495057; font-size: 0.9em;\">Status</label>\n <kendo-dropdownlist [(ngModel)]=\"record.Status\"\n name=\"promptStatus\"\n [data]=\"[{text: 'Active', value: 'Active'}, {text: 'Pending', value: 'Pending'}, {text: 'Disabled', value: 'Disabled'}]\"\n textField=\"text\"\n valueField=\"value\"\n [valuePrimitive]=\"true\"\n style=\"width: 150px;\">\n </kendo-dropdownlist>\n </div>\n <div>\n <label style=\"display: block; margin-bottom: 4px; font-weight: 600; color: #495057; font-size: 0.9em;\">\n Type <span style=\"color: #dc3545;\">*</span>\n </label>\n @if (isLoadingPromptTypes) {\n <div style=\"padding: 8px; color: #6c757d; font-style: italic; width: 200px;\">\n <i class=\"fa-solid fa-spinner fa-spin\"></i> Loading types...\n </div>\n } @else {\n <kendo-dropdownlist [(ngModel)]=\"record.TypeID\"\n name=\"promptTypeID\"\n [data]=\"availablePromptTypes\"\n textField=\"Name\"\n valueField=\"ID\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select prompt type...\"\n style=\"width: 200px;\">\n </kendo-dropdownlist>\n }\n </div>\n </div>\n }\n \n @if (EditMode) {\n <kendo-textarea [(ngModel)]=\"record.Description\" \n name=\"promptDescription\"\n [rows]=\"2\"\n placeholder=\"Enter prompt description...\"\n style=\"width: 100%; max-width: 600px; margin-bottom: 12px;\">\n </kendo-textarea>\n } @else if (record.Description) {\n <p style=\"margin: 0 0 12px 0; color: #6c757d; font-size: 0.9em; line-height: 1.4;\">{{ record.Description }}</p>\n }\n \n <!-- Quick Config Row -->\n <div class=\"quick-config\" style=\"display: flex; align-items: center; gap: 16px; flex-wrap: wrap;\">\n @if (record.TypeID) {\n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-tag\" style=\"color: #6c757d;\"></i>\n <span style=\"color: #6c757d;\">Type:</span>\n <span style=\"color: #495057; font-weight: 500;\">{{ getPromptTypeDisplayName(record.TypeID) }}</span>\n </div>\n }\n \n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-layer-group\" style=\"color: #6c757d;\"></i>\n <span style=\"color: #6c757d;\">Parallelization:</span>\n <span style=\"color: #495057; font-weight: 500;\">{{ getParallelizationModeDisplay() }}</span>\n </div>\n \n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-code\" style=\"color: #6c757d;\"></i>\n <span style=\"color: #6c757d;\">Output:</span>\n <span [style.color]=\"getValidationColor()\" style=\"font-weight: 500;\">{{ getOutputTypeDisplay() }}</span>\n </div>\n \n @if (record.EnableCaching) {\n <div class=\"config-item\" style=\"display: flex; align-items: center; gap: 6px; font-size: 0.85em;\">\n <i class=\"fa-solid fa-database\" style=\"color: #28a745;\"></i>\n <span style=\"color: #28a745; font-weight: 500;\">Caching Enabled</span>\n </div>\n }\n </div>\n </div>\n \n <!-- Right: Action Buttons -->\n <div class=\"action-buttons\" style=\"display: flex; flex-direction: column; gap: 8px; align-items: flex-end;\">\n <div style=\"display: flex; gap: 8px;\">\n @if (record.ID) {\n <button kendoButton [themeColor]=\"'primary'\" [size]=\"'large'\"\n (click)=\"openTestHarness()\"\n title=\"Run AI Prompt Test Harness\">\n <i class=\"fa-solid fa-play\"></i> Run\n </button>\n }\n </div>\n \n @if (!canExecute && record.ID) {\n <div style=\"font-size: 0.75em; color: #dc3545; text-align: right; max-width: 200px;\">\n @if (record.Status !== 'Active') {\n \u2022 Prompt must be Active<br>\n }\n @if (!record.TemplateID) {\n \u2022 Template is required<br>\n }\n @if (!template && record.TemplateID) {\n \u2022 Template not found<br>\n }\n </div>\n }\n </div>\n </div>\n </div>\n\n <!-- Configuration Sections with Expansion Panels -->\n <div class=\"configuration-sections\" style=\"flex: 1; background: white; border-top: 2px solid #e9ecef; padding: 16px; min-height: 0;\">\n <!-- Template Editor Section -->\n <kendo-expansionpanel \n [expanded]=\"true\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-code\" style=\"color: #6c757d;\"></i>\n Template Editor\n @if (template) {\n <span style=\"color: #6c757d; font-size: 0.9em; font-weight: normal;\">\u2022 {{ template.Name }}</span>\n }\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div class=\"template-section\" style=\"display: flex; flex-direction: column; min-height: 400px; padding: 8px;\">\n @if (isLoadingTemplate) {\n <div class=\"loading-state\" style=\"flex: 1; display: flex; align-items: center; justify-content: center; color: #6c757d;\">\n <i class=\"fa-solid fa-spinner fa-spin\" style=\"font-size: 24px; margin-right: 12px;\"></i>\n Loading template...\n </div>\n } @else if (!record.TemplateID) {\n <div class=\"no-template-state\" style=\"flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px; color: #6c757d;\">\n <i class=\"fa-solid fa-code\" style=\"font-size: 64px; margin-bottom: 20px; opacity: 0.3;\"></i>\n <h5 style=\"margin-bottom: 12px; color: #495057;\">No Template Associated</h5>\n <p style=\"margin-bottom: 24px; text-align: center; max-width: 400px;\">\n This AI prompt needs a template to define its structure and parameters. \n Create a new template or link to an existing one.\n </p>\n <div style=\"display: flex; gap: 12px;\">\n <button kendoButton [themeColor]=\"'primary'\" (click)=\"createNewTemplate()\">\n <i class=\"fa-solid fa-plus\"></i> Create New Template\n </button>\n <button kendoButton [fillMode]=\"'outline'\" (click)=\"linkExistingTemplate()\">\n <i class=\"fa-solid fa-link\"></i> Link Existing Template\n </button>\n </div>\n </div>\n } @else if (templateNotFoundInDatabase) {\n <div class=\"invalid-template-state\" style=\"flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 40px; color: #dc3545;\">\n <i class=\"fa-solid fa-exclamation-triangle\" style=\"font-size: 64px; margin-bottom: 20px; opacity: 0.7;\"></i>\n <h5 style=\"margin-bottom: 12px;\">Template Not Found</h5>\n <p style=\"margin-bottom: 24px; text-align: center; max-width: 400px;\">\n The referenced template could not be loaded. It may have been deleted or moved.\n </p>\n <div style=\"display: flex; gap: 12px;\">\n <button kendoButton [fillMode]=\"'outline'\" (click)=\"loadTemplate()\">\n <i class=\"fa-solid fa-refresh\"></i> Retry Loading\n </button>\n <button kendoButton [themeColor]=\"'primary'\" (click)=\"createNewTemplate()\">\n <i class=\"fa-solid fa-plus\"></i> Create New Template\n </button>\n </div>\n </div>\n } @else {\n <!-- Active Template Editor -->\n <div class=\"template-editor-container\" style=\"flex: 1; display: flex; flex-direction: column; min-height: 350px;\">\n <!-- Template Editor -->\n <div style=\"flex: 1; background: white; border-radius: 6px; border: 1px solid #e9ecef;\">\n <mj-template-editor \n #templateEditor\n [template]=\"template\"\n [config]=\"templateEditorConfig\"\n (contentChange)=\"onTemplateContentChange($event)\"\n (runTemplate)=\"onTemplateRun($event)\"\n style=\"display: block; min-height: 300px;\">\n </mj-template-editor>\n </div>\n </div>\n }\n </div>\n </kendo-expansionpanel> \n\n <!-- Model Configuration Expansion Panel -->\n @if (record.IsSaved) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-microchip\" style=\"color: #6c757d;\"></i>\n Models\n @if (promptModels.length > 0) {\n <span class=\"badge\" style=\"background: #17a2b8; color: white; padding: 2px 6px; border-radius: 10px; font-size: 0.7em;\">\n {{ promptModels.length }}\n </span>\n }\n <span style=\"color: #6c757d; font-size: 0.8em; font-weight: normal; margin-left: 8px;\">\n <i class=\"fa-solid fa-info-circle\" title=\"Models are tried in order from top to bottom. The first available model will be used.\"></i>\n Priority order (first available model will be used)\n </span>\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <!-- Model Management Interface -->\n <div class=\"model-management\" style=\"border: 1px solid #dee2e6; border-radius: 6px; background: #f8f9fa;\">\n @if (isLoadingModels) {\n <div class=\"loading-state\" style=\"padding: 20px; text-align: center; color: #6c757d;\">\n <i class=\"fa-solid fa-spinner fa-spin\"></i> Loading models...\n </div>\n } @else {\n @if (promptModels.length === 0) {\n <div class=\"empty-state\" style=\"padding: 20px; text-align: center; color: #6c757d;\">\n <i class=\"fa-solid fa-info-circle\"></i> No models configured\n @if (EditMode) {\n <div style=\"margin-top: 10px;\">\n <button kendoButton fillMode=\"outline\" themeColor=\"primary\" size=\"small\"\n (click)=\"addNewModel()\">\n <i class=\"fa-solid fa-plus\"></i> Add Model\n </button>\n </div>\n }\n </div>\n } @else {\n <!-- Priority explanation for multiple models -->\n @if (promptModels.length > 1) {\n <div style=\"padding: 12px 16px; background: #e3f2fd; border-bottom: 1px solid #bbdefb; color: #1565c0; font-size: 0.85em;\">\n <i class=\"fa-solid fa-info-circle\" style=\"margin-right: 6px;\"></i>\n Models are tried in priority order (1, 2, 3...). The first available model that meets requirements will be used for execution.\n </div>\n }\n <!-- Column Headers -->\n <div class=\"model-header\" style=\"display: grid; grid-template-columns: 40px 2fr 1fr 1fr 60px; gap: 12px; padding: 12px 16px; background: #e9ecef; font-weight: 600; font-size: 0.85em; color: #495057; border-bottom: 1px solid #dee2e6;\">\n <div title=\"Priority order - models are tried from top to bottom\">\n <i class=\"fa-solid fa-sort\" style=\"color: #6c757d;\"></i>\n </div>\n <div>AI Model <span style=\"color: #dc3545;\">*</span></div>\n <div>Vendor</div>\n <div>Created</div>\n <div>Actions</div>\n </div>\n \n @for (model of promptModels; track model.ID || $index; let i = $index) {\n <div class=\"model-row\" \n [draggable]=\"EditMode\"\n (dragstart)=\"onDragStart($event, i)\"\n (dragover)=\"onDragOver($event)\"\n (drop)=\"onDrop($event, i)\"\n (dragend)=\"onDragEnd($event)\"\n [style.background]=\"!model.ModelID ? '#fff3cd' : (draggedIndex === i ? '#e3f2fd' : 'white')\"\n [style.border-left]=\"!model.ModelID ? '3px solid #ffc107' : 'none'\"\n [style.opacity]=\"draggedIndex === i ? '0.5' : '1'\"\n style=\"display: grid; grid-template-columns: 40px 2fr 1fr 1fr 60px; gap: 12px; padding: 12px 16px; border-bottom: 1px solid #e9ecef; align-items: start; transition: background 0.2s, opacity 0.2s;\">\n \n <!-- Drag Handle / Priority -->\n <div class=\"drag-handle\" style=\"display: flex; flex-direction: column; align-items: center; justify-content: center; color: #6c757d;\">\n @if (EditMode) {\n <i class=\"fa-solid fa-grip-vertical\" title=\"Drag to reorder priority\" style=\"cursor: move;\"></i>\n <span style=\"font-size: 0.7em; margin-top: 2px;\">#{{ i + 1 }}</span>\n } @else {\n <span style=\"font-size: 0.9em; font-weight: 600;\" title=\"Priority {{ i + 1 }} - Lower numbers are tried first\">#{{ i + 1 }}</span>\n }\n </div>\n \n <!-- Model Selection -->\n <div class=\"model-select\">\n @if (EditMode) {\n <kendo-dropdownlist [(ngModel)]=\"model.ModelID\"\n [name]=\"'modelId_' + i\"\n [data]=\"availableModels\"\n textField=\"Name\"\n valueField=\"ID\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select a model...\"\n (valueChange)=\"onModelChange($event, i)\"\n style=\"width: 100%;\">\n </kendo-dropdownlist>\n } @else {\n <span style=\"font-weight: 500;\">{{ getModelDisplayName(model.ModelID) }}</span>\n }\n </div>\n \n <!-- Vendor -->\n <div class=\"model-vendor\">\n @if (EditMode) {\n @if (model.ModelID) {\n @if (shouldShowVendorDropdown(model.ModelID)) {\n <kendo-dropdownlist [(ngModel)]=\"model.VendorID\"\n [name]=\"'vendorId_' + i\"\n [data]=\"getVendorsForModelSync(model.ModelID)\"\n textField=\"Name\"\n valueField=\"ID\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select vendor...\"\n style=\"width: 100%;\">\n <ng-template kendoDropDownListItemTemplate let-dataItem>\n <span [style.color]=\"getVendorStatusColor(model.ModelID, dataItem.ID)\">\n {{ dataItem.Name }}\n @if (getModelVendorStatus(model.ModelID, dataItem.ID) !== 'Active') {\n <span style=\"font-size: 0.8em; margin-left: 4px;\">({{ getModelVendorStatus(model.ModelID, dataItem.ID) }})</span>\n }\n </span>\n </ng-template>\n </kendo-dropdownlist>\n } @else {\n <!-- Single vendor - just show the name -->\n @if (getVendorsForModelSync(model.ModelID).length === 1) {\n <span [style.color]=\"getVendorStatusColor(model.ModelID, getVendorsForModelSync(model.ModelID)[0].ID)\" style=\"font-size: 0.9em; font-weight: 500;\">\n {{ getVendorsForModelSync(model.ModelID)[0].Name }}\n @if (getModelVendorStatus(model.ModelID, getVendorsForModelSync(model.ModelID)[0].ID) !== 'Active') {\n <span style=\"font-size: 0.8em; margin-left: 4px;\">({{ getModelVendorStatus(model.ModelID, getVendorsForModelSync(model.ModelID)[0].ID) }})</span>\n }\n </span>\n } @else {\n <span style=\"color: #6c757d; font-style: italic; font-size: 0.9em;\">No vendors available</span>\n }\n }\n } @else {\n <span style=\"color: #6c757d; font-style: italic; font-size: 0.9em;\">Select model first</span>\n }\n } @else {\n @if (model.VendorID && model.ModelID) {\n <span [style.color]=\"getVendorStatusColor(model.ModelID, model.VendorID)\" style=\"font-size: 0.9em;\">\n {{ getVendorDisplayName(model.VendorID) }}\n @if (getModelVendorStatus(model.ModelID, model.VendorID) !== 'Active') {\n <span style=\"font-size: 0.8em; margin-left: 4px;\">({{ getModelVendorStatus(model.ModelID, model.VendorID) }})</span>\n }\n </span>\n } @else {\n <span style=\"color: #6c757d; font-size: 0.9em;\">-</span>\n }\n }\n </div>\n \n \n <!-- Created Date -->\n <div class=\"model-created\">\n @if (model.ID) {\n <span style=\"color: #6c757d; font-size: 0.8em;\">{{ model.__mj_CreatedAt | date:'short' }}</span>\n } @else {\n <span style=\"color: #28a745; font-size: 0.8em; font-style: italic;\">New</span>\n }\n </div>\n \n <!-- Actions -->\n <div class=\"model-actions\" style=\"display: flex; gap: 2px; flex-direction: column;\">\n @if (EditMode) {\n <div style=\"display: flex; gap: 2px; margin-bottom: 4px;\">\n <button kendoButton fillMode=\"flat\" size=\"small\"\n (click)=\"moveModelUp(i)\"\n [disabled]=\"i === 0\"\n title=\"Move up\">\n <i class=\"fa-solid fa-chevron-up\"></i>\n </button>\n <button kendoButton fillMode=\"flat\" size=\"small\"\n (click)=\"moveModelDown(i)\"\n [disabled]=\"i === promptModels.length - 1\"\n title=\"Move down\">\n <i class=\"fa-solid fa-chevron-down\"></i>\n </button>\n </div>\n <button kendoButton fillMode=\"flat\" themeColor=\"error\" size=\"small\"\n (click)=\"removePromptModel(i)\"\n title=\"Remove model\">\n <i class=\"fa-solid fa-times\"></i>\n </button>\n }\n </div>\n </div>\n \n <!-- Second row with additional details -->\n <div style=\"display: grid; grid-template-columns: 40px 1fr; gap: 12px; padding: 8px 16px; border-bottom: 1px solid #e9ecef; background: #f8f9fa; font-size: 0.85em; color: #6c757d;\">\n <div></div>\n <div>\n <!-- Basic model details -->\n <div style=\"display: flex; gap: 16px; flex-wrap: wrap; align-items: center; margin-bottom: 8px;\">\n @if (model.Status) {\n <span><strong>Status:</strong> {{ model.Status }}</span>\n }\n @if (model.ConfigurationID) {\n <span><strong>Configuration:</strong> {{ model.ConfigurationID }}</span>\n }\n </div>\n \n <!-- Parallel execution fields when prompt is ModelSpecific -->\n @if (record.ParallelizationMode === 'ModelSpecific') {\n <div style=\"padding: 8px; background: #fff; border: 1px solid #dee2e6; border-radius: 4px; margin-top: 8px;\">\n <div style=\"margin-bottom: 6px; font-weight: 600; color: #495057; font-size: 0.9em;\">\n <i class=\"fa-solid fa-layer-group\"></i> Model-Specific Parallel Execution\n </div>\n \n @if (EditMode) {\n <div style=\"display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 12px; align-items: center;\">\n <!-- Parallel Mode -->\n <div>\n <label style=\"display: block; margin-bottom: 2px; font-size: 0.8em; font-weight: 600; color: #495057;\">Parallel Mode</label>\n <kendo-dropdownlist [(ngModel)]=\"model.ParallelizationMode\"\n [name]=\"'parallelMode_' + i\"\n [data]=\"[{text: 'None', value: 'None'}, {text: 'Static Count', value: 'StaticCount'}, {text: 'Config Param', value: 'ConfigParam'}]\"\n textField=\"text\"\n valueField=\"value\"\n [valuePrimitive]=\"true\"\n placeholder=\"Select mode...\"\n style=\"width: 100%; font-size: 0.85em;\">\n </kendo-dropdownlist>\n </div>\n \n <!-- Parallel Count (when StaticCount) -->\n @if (model.ParallelizationMode === 'StaticCount') {\n <div>\n <label style=\"display: block; margin-bottom: 2px; font-size: 0.8em; font-weight: 600; color: #495057;\">Parallel Count</label>\n <kendo-numerictextbox [(ngModel)]=\"model.ParallelCount\"\n [name]=\"'parallelCount_' + i\"\n [min]=\"1\"\n [step]=\"1\"\n [format]=\"'n0'\"\n placeholder=\"Count...\"\n style=\"width: 100%; font-size: 0.85em;\">\n </kendo-numerictextbox>\n </div>\n }\n \n <!-- Config Param (when ConfigParam) -->\n @if (model.ParallelizationMode === 'ConfigParam') {\n <div>\n <label style=\"display: block; margin-bottom: 2px; font-size: 0.8em; font-weight: 600; color: #495057;\">Config Parameter</label>\n <kendo-textbox [(ngModel)]=\"model.ParallelConfigParam\"\n [name]=\"'parallelConfigParam_' + i\"\n placeholder=\"Parameter name...\"\n style=\"width: 100%; font-size: 0.85em;\">\n </kendo-textbox>\n </div>\n }\n </div>\n } @else {\n <!-- Read-only display -->\n <div style=\"display: flex; gap: 16px; flex-wrap: wrap; align-items: center;\">\n @if (model.ParallelizationMode) {\n <span><strong>Parallel Mode:</strong> {{ model.ParallelizationMode }}</span>\n }\n @if (model.ParallelCount) {\n <span><strong>Parallel Count:</strong> {{ model.ParallelCount }}</span>\n }\n @if (model.ParallelConfigParam) {\n <span><strong>Config Param:</strong> {{ model.ParallelConfigParam }}</span>\n }\n </div>\n }\n </div>\n }\n </div>\n </div>\n }\n \n @if (EditMode) {\n <div class=\"add-model-row\" style=\"padding: 12px 16px; text-align: center; background: #f8f9fa; border-top: 1px solid #dee2e6;\">\n <button kendoButton fillMode=\"outline\" themeColor=\"success\" size=\"small\"\n (click)=\"addNewModel()\">\n <i class=\"fa-solid fa-plus\"></i> Add Model\n </button>\n </div>\n }\n }\n }\n </div>\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Advanced Configuration Expansion Panel -->\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-cogs\" style=\"color: #6c757d;\"></i>\n Advanced Configuration\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <div style=\"display: grid; grid-template-columns: 1fr 1fr; gap: 20px;\">\n \n <!-- Left Column -->\n <div>\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ParallelizationMode\"\n Type=\"dropdownlist\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n @if (showParallelCount) {\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ParallelCount\"\n Type=\"numerictextbox\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n }\n \n @if (showParallelConfigParam) {\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ParallelConfigParam\"\n Type=\"textbox\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n }\n \n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"OutputType\"\n Type=\"dropdownlist\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n </div>\n \n <!-- Right Column -->\n <div>\n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"ValidationBehavior\"\n Type=\"dropdownlist\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n <mj-form-field \n [record]=\"record\"\n [ShowLabel]=\"true\"\n FieldName=\"EnableCaching\"\n Type=\"checkbox\"\n [EditMode]=\"EditMode\">\n </mj-form-field>\n \n <!-- Result Selector Prompt with Tree Selector -->\n <div style=\"margin-bottom: 16px;\">\n <label style=\"display: block; margin-bottom: 4px; font-weight: 600; color: #495057; font-size: 0.9em;\">\n Result Selector Prompt\n </label>\n @if (EditMode) {\n @if (isLoadingResultSelectorData) {\n <div style=\"padding: 8px; color: #6c757d; font-style: italic;\">\n <i class=\"fa-solid fa-spinner fa-spin\"></i> Loading prompts...\n </div>\n } @else {\n <kendo-dropdowntree \n [(ngModel)]=\"record.ResultSelectorPromptID\"\n name=\"resultSelectorPromptID\"\n [data]=\"resultSelectorTreeData\"\n textField=\"text\"\n valueField=\"value\"\n [valuePrimitive]=\"true\"\n [filterable]=\"true\"\n placeholder=\"Select a result selector prompt...\"\n style=\"width: 100%;\"\n (valueChange)=\"onResultSelectorChange($event)\">\n </kendo-dropdowntree>\n }\n } @else {\n <span style=\"color: #495057;\">{{ getPromptDisplayName(record.ResultSelectorPromptID || '') || 'None selected' }}</span>\n }\n </div>\n </div>\n </div>\n </div>\n </kendo-expansionpanel>\n\n <!-- Output Example Expansion Panel (when OutputType = object) -->\n @if (showOutputExample) {\n <kendo-expansionpanel \n [expanded]=\"true\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-code\" style=\"color: #6c757d;\"></i>\n Output Example (JSON)\n <span style=\"color: #dc3545; font-size: 0.8em; font-weight: normal;\">\u2022 Required for object output type</span>\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px;\">\n @if (EditMode) {\n <mj-code-editor \n [(ngModel)]=\"record.OutputExample\"\n name=\"outputExample\"\n language=\"json\"\n placeholder=\"Enter JSON example structure...\"\n style=\"width: 100%; height: 200px; border: 1px solid #dee2e6; border-radius: 4px;\">\n </mj-code-editor>\n <div style=\"margin-top: 8px; color: #6c757d; font-size: 0.85em;\">\n <i class=\"fa-solid fa-info-circle\"></i> Provide a JSON example that defines the expected structure for object output validation.\n </div>\n } @else if (record.OutputExample) {\n <div style=\"background: #f8f9fa; border: 1px solid #dee2e6; border-radius: 4px; padding: 12px; font-family: 'Courier New', monospace; font-size: 0.9em; white-space: pre-wrap; overflow: auto; max-height: 250px;\">{{ record.OutputExample }}</div>\n } @else {\n <div style=\"background: #fff3cd; border: 1px solid #ffeaa7; border-radius: 4px; padding: 12px; color: #856404; text-align: center;\">\n <i class=\"fa-solid fa-exclamation-triangle\"></i> Output example is required when output type is 'object'\n </div>\n }\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Execution History Expansion Panel -->\n @if (record.IsSaved) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-history\" style=\"color: #6c757d;\"></i>\n Execution History\n @if (executionHistory.length > 0) {\n <span style=\"color: #6c757d; font-weight: normal;\">({{ executionHistory.length }})</span>\n }\n </span>\n </ng-template>\n \n <!-- Custom Execution History Viewer -->\n <div style=\"padding: 16px;\">\n @if (isLoadingHistory) {\n <div style=\"text-align: center; padding: 40px; color: #6c757d;\">\n <i class=\"fa-solid fa-spinner fa-spin\" style=\"font-size: 2em; margin-bottom: 12px;\"></i>\n <p>Loading execution history...</p>\n </div>\n } @else if (executionHistory.length === 0) {\n <div style=\"text-align: center; padding: 40px; color: #6c757d;\">\n <i class=\"fa-solid fa-history\" style=\"font-size: 3em; margin-bottom: 12px; opacity: 0.3;\"></i>\n <p>No execution history yet</p>\n <p style=\"font-size: 0.9em;\">Run this prompt to see execution history here</p>\n </div>\n } @else {\n <!-- Sort Controls -->\n <div style=\"display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px;\">\n <div style=\"color: #6c757d; font-size: 0.9em;\">\n Showing {{ executionHistory.length }} executions\n </div>\n <div style=\"display: flex; gap: 8px; align-items: center;\">\n <span style=\"color: #6c757d; font-size: 0.85em;\">Sort by:</span>\n <kendo-buttongroup selection=\"single\">\n <button kendoButton \n [selected]=\"historySortField === 'runAt'\"\n (click)=\"changeHistorySort('runAt')\"\n size=\"small\">\n Date\n @if (historySortField === 'runAt') {\n <i [class]=\"'fa-solid fa-sort-' + (historySortDirection === 'asc' ? 'up' : 'down')\" \n style=\"margin-left: 4px; font-size: 0.8em;\"></i>\n }\n </button>\n <button kendoButton \n [selected]=\"historySortField === 'executionTime'\"\n (click)=\"changeHistorySort('executionTime')\"\n size=\"small\">\n Duration\n @if (historySortField === 'executionTime') {\n <i [class]=\"'fa-solid fa-sort-' + (historySortDirection === 'asc' ? 'up' : 'down')\" \n style=\"margin-left: 4px; font-size: 0.8em;\"></i>\n }\n </button>\n <button kendoButton \n [selected]=\"historySortField === 'tokens'\"\n (click)=\"changeHistorySort('tokens')\"\n size=\"small\">\n Tokens\n @if (historySortField === 'tokens') {\n <i [class]=\"'fa-solid fa-sort-' + (historySortDirection === 'asc' ? 'up' : 'down')\" \n style=\"margin-left: 4px; font-size: 0.8em;\"></i>\n }\n </button>\n <button kendoButton \n [selected]=\"historySortField === 'cost'\"\n (click)=\"changeHistorySort('cost')\"\n size=\"small\">\n Cost\n @if (historySortField === 'cost') {\n <i [class]=\"'fa-solid fa-sort-' + (historySortDirection === 'asc' ? 'up' : 'down')\" \n style=\"margin-left: 4px; font-size: 0.8em;\"></i>\n }\n </button>\n </kendo-buttongroup>\n </div>\n </div>\n \n <!-- Execution History Table -->\n <div style=\"border: 1px solid #e9ecef; border-radius: 8px; overflow: hidden;\">\n <table style=\"width: 100%; border-collapse: collapse;\">\n <thead>\n <tr style=\"background: #f8f9fa; border-bottom: 2px solid #e9ecef;\">\n <th style=\"padding: 12px; text-align: left; font-weight: 600; color: #495057;\">Status</th>\n <th style=\"padding: 12px; text-align: left; font-weight: 600; color: #495057;\">Date & Time</th>\n <th style=\"padding: 12px; text-align: left; font-weight: 600; color: #495057;\">Model</th>\n <th style=\"padding: 12px; text-align: left; font-weight: 600; color: #495057;\">Duration</th>\n <th style=\"padding: 12px; text-align: right; font-weight: 600; color: #495057;\">Tokens</th>\n <th style=\"padding: 12px; text-align: right; font-weight: 600; color: #495057;\">Cost</th>\n <th style=\"padding: 12px; text-align: center; font-weight: 600; color: #495057;\">Type</th>\n <th style=\"padding: 12px; text-align: center; font-weight: 600; color: #495057;\">Actions</th>\n </tr>\n </thead>\n <tbody>\n @for (run of executionHistory; track run.ID; let i = $index) {\n <tr class=\"history-row\"\n [class.even-row]=\"i % 2 === 0\"\n style=\"border-bottom: 1px solid #f1f3f5;\">\n <td style=\"padding: 12px;\">\n <span style=\"display: flex; align-items: center; gap: 6px;\">\n <i [class]=\"'fa-solid ' + getExecutionStatusIcon(run.Success)\" \n [style.color]=\"getExecutionStatusColor(run.Success)\"></i>\n <span [style.color]=\"getExecutionStatusColor(run.Success)\" style=\"font-weight: 500;\">\n {{ run.Success === true ? 'Success' : run.Success === false ? 'Failed' : 'Running' }}\n </span>\n </span>\n </td>\n <td style=\"padding: 12px; color: #495057;\">\n {{ run.RunAt | date:'short' }}\n </td>\n <td style=\"padding: 12px; color: #495057;\">\n <span style=\"display: flex; align-items: center; gap: 6px;\">\n <i class=\"fa-solid fa-microchip\" style=\"color: #6c757d;\"></i>\n {{ run.Model || 'Unknown' }}\n </span>\n </td>\n <td style=\"padding: 12px; color: #495057;\">\n {{ formatDuration(run.ExecutionTimeMS) }}\n </td>\n <td style=\"padding: 12px; text-align: right; color: #495057;\">\n {{ formatTokens(run.TokensUsed) }}\n </td>\n <td style=\"padding: 12px; text-align: right; color: #495057;\">\n {{ formatCost(run.TotalCost || run.Cost) }}\n </td>\n <td style=\"padding: 12px; text-align: center;\">\n @if (run.RunType) {\n <span style=\"padding: 4px 8px; border-radius: 12px; background: #e9ecef; \n color: #495057; font-size: 0.85em; font-weight: 500;\">\n {{ run.RunType }}\n </span>\n }\n </td>\n <td style=\"padding: 12px; text-align: center;\">\n <button kendoButton \n fillMode=\"flat\"\n size=\"small\"\n (click)=\"navigateToPromptRun(run.ID)\"\n title=\"View details\">\n <i class=\"fa-solid fa-external-link\"></i>\n </button>\n </td>\n </tr>\n }\n </tbody>\n </table>\n </div>\n }\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Cache Expansion Panel -->\n @if (record.IsSaved && record.EnableCaching) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-database\" style=\"color: #6c757d;\"></i>\n Result Cache\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <mj-user-view-grid \n [Params]=\"BuildRelationshipViewParamsByEntityName('AI Result Cache','AIPromptID')\" \n [NewRecordValues]=\"NewRecordValues('AI Result Cache')\"\n [AllowLoad]=\"true\"\n [EditMode]=\"GridEditMode()\" \n [BottomMargin]=\"0\"\n style=\"height: 300px;\">\n </mj-user-view-grid>\n </div>\n </kendo-expansionpanel>\n }\n\n <!-- Related Items Expansion Panel -->\n @if (record.IsSaved) {\n <kendo-expansionpanel \n [expanded]=\"false\"\n style=\"margin-bottom: 12px;\">\n <ng-template kendoExpansionPanelTitleDirective>\n <span style=\"display: flex; align-items: center; gap: 8px; font-weight: 600;\">\n <i class=\"fa-solid fa-link\" style=\"color: #6c757d;\"></i>\n Related Items\n </span>\n </ng-template>\n \n <!-- Direct Content Projection -->\n <div style=\"padding: 16px 0;\">\n <div style=\"display: grid; grid-template-columns: 1fr 1fr; gap: 20px;\">\n <!-- AI Agents -->\n <div>\n <h6 style=\"margin: 0 0 12px 0; color: #495057;\">AI Agents Using This Prompt</h6>\n <mj-user-view-grid \n [Params]=\"BuildRelationshipViewParamsByEntityName('MJ: AI Agent Prompts','PromptID')\" \n [NewRecordValues]=\"NewRecordValues('MJ: AI Agent Prompts')\"\n [AllowLoad]=\"true\"\n [EditMode]=\"GridEditMode()\" \n [BottomMargin]=\"0\"\n style=\"height: 200px;\">\n </mj-user-view-grid>\n </div>\n \n <!-- Result Selector References -->\n <div>\n <h6 style=\"margin: 0 0 12px 0; color: #495057;\">Prompts Using This as Result Selector</h6>\n <mj-user-view-grid \n [Params]=\"BuildRelationshipViewParamsByEntityName('AI Prompts','ResultSelectorPromptID')\" \n [NewRecordValues]=\"NewRecordValues('AI Prompts')\"\n [AllowLoad]=\"true\"\n [EditMode]=\"GridEditMode()\" \n [BottomMargin]=\"0\"\n style=\"height: 200px;\">\n </mj-user-view-grid>\n </div>\n </div>\n </div>\n </kendo-expansionpanel>\n }\n </div>\n </div>\n </form>\n\n \n <!-- AI Prompt Test Harness -->\n @if (showTestHarness) {\n <kendo-window \n [width]=\"1200\" \n [height]=\"800\" \n [minWidth]=\"800\"\n [minHeight]=\"600\"\n [draggable]=\"true\"\n [resizable]=\"true\"\n [state]=\"'default'\"\n (close)=\"onTestHarnessVisibilityChanged(false)\"\n title=\"Run AI Prompt - {{ record.Name || 'Untitled' }}\">\n <mj-ai-test-harness\n [entity]=\"record\"\n [mode]=\"'prompt'\"\n [isVisible]=\"showTestHarness\"\n (visibilityChange)=\"onTestHarnessVisibilityChanged($event)\">\n </mj-ai-test-harness>\n </kendo-window>\n }\n</div>", styles: [".record-form-container {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n padding: 10px;\n}\n\n.custom-toolbar-actions {\n margin-left: auto;\n}\n\n.status-badge {\n font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;\n font-weight: 500;\n letter-spacing: 0.02em;\n}\n\n.config-summary {\n position: sticky;\n top: 0;\n max-height: 600px;\n overflow-y: auto;\n}\n\n.config-item {\n padding: 8px 0;\n border-bottom: 1px solid #e9ecef;\n}\n\n.config-item:last-child {\n border-bottom: none;\n}\n\n.template-tab-content {\n background: #fff;\n}\n\n.template-header h5 {\n font-size: 1.1em;\n}\n\n.loading-state,\n.no-template-state,\n.invalid-template-state {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n}\n\n.no-template-state i,\n.invalid-template-state i {\n opacity: 0.6;\n}\n\n.template-editor-container {\n background: #fff;\n border-radius: 6px;\n}\n\n/* Grid layout adjustments */\n@media (max-width: 1200px) {\n .record-form-container .mj-tab-body > div {\n grid-template-columns: 1fr !important;\n gap: 20px;\n }\n \n .config-summary {\n order: -1;\n position: static;\n max-height: none;\n }\n}\n\n/* Responsive toolbar */\n@media (max-width: 768px) {\n .custom-toolbar-actions {\n flex-direction: column;\n gap: 4px !important;\n }\n \n .status-badge {\n align-self: flex-start;\n }\n}\n\n/* Ensure proper spacing in form sections */\n.record-form-container mj-form-section {\n padding: 16px;\n}\n\n/* Smooth transitions for better UX */\n.status-badge,\n.config-item,\n.template-header {\n transition: all 0.2s ease;\n}\n\n.config-item:hover {\n background-color: rgba(0,0,0,0.02);\n border-radius: 4px;\n margin: 0 -8px;\n padding: 8px;\n}\n\n/* Execution History Table Styles */\n.history-row {\n transition: background 0.2s;\n}\n\n.history-row:not(.even-row) {\n background: #f8f9fa;\n}\n\n.history-row.even-row {\n background: white;\n}\n\n.history-row:hover {\n background: #e9ecef !important;\n}"] }]
2287
2291
  }], () => [{ type: i0.ElementRef }, { type: i1.SharedService }, { type: i2.Router }, { type: i2.ActivatedRoute }, { type: i0.ChangeDetectorRef }], { templateEditor: [{
2288
2292
  type: ViewChild,
2289
2293
  args: ['templateEditor']