@memberjunction/ng-core-entity-forms 2.53.0 → 2.55.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -206
- package/dist/lib/custom/AIAgents/ai-agent-form.component.d.ts +28 -5
- package/dist/lib/custom/AIAgents/ai-agent-form.component.d.ts.map +1 -1
- package/dist/lib/custom/AIAgents/ai-agent-form.component.js +364 -234
- package/dist/lib/custom/AIAgents/ai-agent-form.component.js.map +1 -1
- package/dist/lib/custom/AIAgents/new-agent-dialog.component.d.ts +36 -0
- package/dist/lib/custom/AIAgents/new-agent-dialog.component.d.ts.map +1 -0
- package/dist/lib/custom/AIAgents/new-agent-dialog.component.js +325 -0
- package/dist/lib/custom/AIAgents/new-agent-dialog.component.js.map +1 -0
- package/dist/lib/custom/AIAgents/new-agent-dialog.service.d.ts +41 -0
- package/dist/lib/custom/AIAgents/new-agent-dialog.service.d.ts.map +1 -0
- package/dist/lib/custom/AIAgents/new-agent-dialog.service.js +87 -0
- package/dist/lib/custom/AIAgents/new-agent-dialog.service.js.map +1 -0
- package/dist/lib/custom/AIPromptRuns/ai-prompt-run-form.component.js +5 -7
- package/dist/lib/custom/AIPromptRuns/ai-prompt-run-form.component.js.map +1 -1
- package/dist/lib/custom/AIPrompts/ai-prompt-form.component.d.ts +5 -2
- package/dist/lib/custom/AIPrompts/ai-prompt-form.component.d.ts.map +1 -1
- package/dist/lib/custom/AIPrompts/ai-prompt-form.component.js +501 -485
- package/dist/lib/custom/AIPrompts/ai-prompt-form.component.js.map +1 -1
- package/dist/lib/custom/Actions/action-execution-log-form.component.d.ts +2 -0
- package/dist/lib/custom/Actions/action-execution-log-form.component.d.ts.map +1 -1
- package/dist/lib/custom/Actions/action-execution-log-form.component.js +216 -293
- package/dist/lib/custom/Actions/action-execution-log-form.component.js.map +1 -1
- package/dist/lib/custom/Actions/action-form.component.js +6 -8
- package/dist/lib/custom/Actions/action-form.component.js.map +1 -1
- package/dist/lib/custom/ai-agent-run/ai-agent-run-step-node.component.d.ts +25 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run-step-node.component.d.ts.map +1 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run-step-node.component.js +261 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run-step-node.component.js.map +1 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run-timeline.component.d.ts +73 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run-timeline.component.d.ts.map +1 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run-timeline.component.js +510 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run-timeline.component.js.map +1 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run.component.d.ts +41 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run.component.d.ts.map +1 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run.component.js +568 -0
- package/dist/lib/custom/ai-agent-run/ai-agent-run.component.js.map +1 -0
- package/dist/lib/custom/custom-forms.module.d.ts +31 -31
- package/dist/lib/custom/custom-forms.module.d.ts.map +1 -1
- package/dist/lib/custom/custom-forms.module.js +37 -34
- package/dist/lib/custom/custom-forms.module.js.map +1 -1
- package/dist/lib/generated/Entities/AIAgent/aiagent.form.component.js +16 -17
- package/dist/lib/generated/Entities/AIAgent/aiagent.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIAgentRun/aiagentrun.form.component.js +11 -14
- package/dist/lib/generated/Entities/AIAgentRun/aiagentrun.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIAgentRunStep/aiagentrunstep.form.component.js +3 -5
- package/dist/lib/generated/Entities/AIAgentRunStep/aiagentrunstep.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIAgentRunStep/sections/details.component.d.ts.map +1 -1
- package/dist/lib/generated/Entities/AIAgentRunStep/sections/details.component.js +13 -4
- package/dist/lib/generated/Entities/AIAgentRunStep/sections/details.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIAgentType/aiagenttype.form.component.js +5 -7
- package/dist/lib/generated/Entities/AIAgentType/aiagenttype.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIConfiguration/aiconfiguration.form.component.js +7 -8
- package/dist/lib/generated/Entities/AIConfiguration/aiconfiguration.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIModel/aimodel.form.component.js +12 -13
- package/dist/lib/generated/Entities/AIModel/aimodel.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIModelCost/aimodelcost.form.component.js +3 -5
- package/dist/lib/generated/Entities/AIModelCost/aimodelcost.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIModelPriceType/aimodelpricetype.form.component.js +5 -7
- package/dist/lib/generated/Entities/AIModelPriceType/aimodelpricetype.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIModelPriceUnitType/aimodelpriceunittype.form.component.js +5 -7
- package/dist/lib/generated/Entities/AIModelPriceUnitType/aimodelpriceunittype.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIModelType/aimodeltype.form.component.js +11 -12
- package/dist/lib/generated/Entities/AIModelType/aimodeltype.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIPrompt/aiprompt.form.component.js +19 -20
- package/dist/lib/generated/Entities/AIPrompt/aiprompt.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIPromptRun/aipromptrun.form.component.js +11 -12
- package/dist/lib/generated/Entities/AIPromptRun/aipromptrun.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIPromptRun/sections/details.component.d.ts.map +1 -1
- package/dist/lib/generated/Entities/AIPromptRun/sections/details.component.js +13 -4
- package/dist/lib/generated/Entities/AIPromptRun/sections/details.component.js.map +1 -1
- package/dist/lib/generated/Entities/AIVendor/aivendor.form.component.js +15 -16
- package/dist/lib/generated/Entities/AIVendor/aivendor.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/Action/action.form.component.js +5 -5
- package/dist/lib/generated/Entities/Action/action.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/ActionAuthorization/actionauthorization.form.component.js +1 -1
- package/dist/lib/generated/Entities/ActionAuthorization/actionauthorization.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/ActionContext/actioncontext.form.component.js +1 -1
- package/dist/lib/generated/Entities/ActionContext/actioncontext.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/Conversation/conversation.form.component.js +5 -5
- package/dist/lib/generated/Entities/Conversation/conversation.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/TemplateContent/templatecontent.form.component.js +4 -4
- package/dist/lib/generated/Entities/TemplateContent/templatecontent.form.component.js.map +1 -1
- package/dist/lib/generated/Entities/User/user.form.component.js +5 -5
- package/dist/lib/generated/Entities/User/user.form.component.js.map +1 -1
- package/dist/public-api.d.ts +2 -3
- package/dist/public-api.d.ts.map +1 -1
- package/dist/public-api.js +3 -16
- package/dist/public-api.js.map +1 -1
- package/package.json +13 -12
- package/dist/lib/custom/ai-test-harness/agent-execution-monitor.component.d.ts +0 -244
- package/dist/lib/custom/ai-test-harness/agent-execution-monitor.component.d.ts.map +0 -1
- package/dist/lib/custom/ai-test-harness/agent-execution-monitor.component.js +0 -1327
- package/dist/lib/custom/ai-test-harness/agent-execution-monitor.component.js.map +0 -1
- package/dist/lib/custom/ai-test-harness/agent-execution-node.component.d.ts +0 -19
- package/dist/lib/custom/ai-test-harness/agent-execution-node.component.d.ts.map +0 -1
- package/dist/lib/custom/ai-test-harness/agent-execution-node.component.js +0 -458
- package/dist/lib/custom/ai-test-harness/agent-execution-node.component.js.map +0 -1
- package/dist/lib/custom/ai-test-harness/ai-test-harness-dialog.component.d.ts +0 -78
- package/dist/lib/custom/ai-test-harness/ai-test-harness-dialog.component.d.ts.map +0 -1
- package/dist/lib/custom/ai-test-harness/ai-test-harness-dialog.component.js +0 -157
- package/dist/lib/custom/ai-test-harness/ai-test-harness-dialog.component.js.map +0 -1
- package/dist/lib/custom/ai-test-harness/ai-test-harness.component.d.ts +0 -598
- package/dist/lib/custom/ai-test-harness/ai-test-harness.component.d.ts.map +0 -1
- package/dist/lib/custom/ai-test-harness/ai-test-harness.component.js +0 -3204
- package/dist/lib/custom/ai-test-harness/ai-test-harness.component.js.map +0 -1
- package/dist/lib/custom/ai-test-harness/json-viewer-window.component.d.ts +0 -8
- package/dist/lib/custom/ai-test-harness/json-viewer-window.component.d.ts.map +0 -1
- package/dist/lib/custom/ai-test-harness/json-viewer-window.component.js +0 -57
- package/dist/lib/custom/ai-test-harness/json-viewer-window.component.js.map +0 -1
- package/dist/lib/custom/test-harness-dialog.service.d.ts +0 -111
- package/dist/lib/custom/test-harness-dialog.service.d.ts.map +0 -1
- package/dist/lib/custom/test-harness-dialog.service.js +0 -211
- package/dist/lib/custom/test-harness-dialog.service.js.map +0 -1
package/README.md
CHANGED
|
@@ -23,7 +23,6 @@ npm install @memberjunction/ng-core-entity-forms
|
|
|
23
23
|
- Angular 18+
|
|
24
24
|
- @memberjunction/core
|
|
25
25
|
- @memberjunction/core-entities
|
|
26
|
-
- @memberjunction/ng-explorer-core
|
|
27
26
|
- @memberjunction/ng-base-forms
|
|
28
27
|
- Various MemberJunction and Kendo UI components
|
|
29
28
|
|
|
@@ -218,195 +217,10 @@ Each entity form typically follows this structure:
|
|
|
218
217
|
| AI-related forms | Forms for AI models, prompts, and agents |
|
|
219
218
|
| Content forms | Forms for content management |
|
|
220
219
|
| Communication forms | Forms for messaging and notifications |
|
|
221
|
-
| **Test Harness Components** | **Interactive testing interfaces for AI agents and prompts** |
|
|
222
|
-
|
|
223
|
-
## AI Test Harness System
|
|
224
|
-
|
|
225
|
-
This package includes a comprehensive test harness system for AI Agents and AI Prompts, providing developers with powerful tools for testing, debugging, and validating AI components.
|
|
226
|
-
|
|
227
|
-
### Test Harness Components
|
|
228
|
-
|
|
229
|
-
#### 1. AI Agent Test Harness (`AIAgentTestHarnessComponent`)
|
|
230
|
-
|
|
231
|
-
A full-featured testing interface for AI agents with the following capabilities:
|
|
232
|
-
|
|
233
|
-
**Core Features:**
|
|
234
|
-
- **Interactive Chat Interface**: Real-time conversation with AI agents
|
|
235
|
-
- **Streaming Support**: Live streaming of agent responses with elapsed time tracking
|
|
236
|
-
- **Data Context Management**: Configure variables passed to agents during execution
|
|
237
|
-
- **Template Data Management**: Manage template variables for agent prompts
|
|
238
|
-
- **Conversation Persistence**: Save/load conversations with full state restoration
|
|
239
|
-
- **Import/Export**: JSON-based conversation backup and sharing
|
|
240
|
-
- **Content Formatting**: Automatic detection and rendering of Markdown, JSON, and plain text
|
|
241
|
-
- **Raw Content Toggle**: View both processed and raw AI responses
|
|
242
|
-
- **Error Handling**: Comprehensive error display and user feedback
|
|
243
|
-
|
|
244
|
-
**Usage Example:**
|
|
245
|
-
```html
|
|
246
|
-
<mj-ai-agent-test-harness
|
|
247
|
-
[aiAgent]="myAgent"
|
|
248
|
-
[isVisible]="true"
|
|
249
|
-
(visibilityChange)="onVisibilityChanged($event)">
|
|
250
|
-
</mj-ai-agent-test-harness>
|
|
251
|
-
```
|
|
252
|
-
|
|
253
|
-
**Data Context Configuration:**
|
|
254
|
-
```typescript
|
|
255
|
-
// Configure variables passed to the agent
|
|
256
|
-
this.testHarness.dataContextVariables = [
|
|
257
|
-
{ name: 'userId', value: 'user-123', type: 'string' },
|
|
258
|
-
{ name: 'department', value: 'Engineering', type: 'string' },
|
|
259
|
-
{ name: 'priority', value: '1', type: 'number' }
|
|
260
|
-
];
|
|
261
|
-
```
|
|
262
|
-
|
|
263
|
-
#### 2. AI Prompt Test Harness (`AIPromptTestHarnessComponent`)
|
|
264
|
-
|
|
265
|
-
A specialized testing interface for AI prompts with template variable management:
|
|
266
|
-
|
|
267
|
-
**Core Features:**
|
|
268
|
-
- **Prompt Testing**: Execute prompts with different AI models
|
|
269
|
-
- **Template Variable Management**: Configure and test prompt variables
|
|
270
|
-
- **Model Selection**: Choose from available AI models for testing
|
|
271
|
-
- **Rendered Prompt Preview**: View how templates render with current variables
|
|
272
|
-
- **Conversation Management**: Similar conversation features as agent harness
|
|
273
|
-
- **Variable Auto-Detection**: Automatically detect variables in prompt templates
|
|
274
|
-
|
|
275
|
-
**Usage Example:**
|
|
276
|
-
```html
|
|
277
|
-
<mj-ai-prompt-test-harness
|
|
278
|
-
[aiPrompt]="myPrompt"
|
|
279
|
-
[template]="promptTemplate"
|
|
280
|
-
[templateContent]="templateContent"
|
|
281
|
-
[isVisible]="true">
|
|
282
|
-
</mj-ai-prompt-test-harness>
|
|
283
|
-
```
|
|
284
|
-
|
|
285
|
-
#### 3. Test Harness Dialog Service (`TestHarnessDialogService`)
|
|
286
|
-
|
|
287
|
-
A centralized service for opening test harnesses in modal dialogs:
|
|
288
|
-
|
|
289
|
-
**Features:**
|
|
290
|
-
- **Configurable Dialogs**: Custom sizing, titles, and initial data
|
|
291
|
-
- **Agent Loading**: Load agents by ID or use existing entities
|
|
292
|
-
- **Dimension Support**: Viewport units (vw, vh) and pixel dimensions
|
|
293
|
-
- **Initial Data Setup**: Pre-populate context and template variables
|
|
294
|
-
|
|
295
|
-
**Usage Examples:**
|
|
296
|
-
```typescript
|
|
297
|
-
// Open AI Agent test harness
|
|
298
|
-
const dialogRef = this.testHarnessService.openAgentTestHarness({
|
|
299
|
-
agentId: 'agent-123',
|
|
300
|
-
title: 'Test My Agent',
|
|
301
|
-
width: '90vw',
|
|
302
|
-
height: '80vh',
|
|
303
|
-
initialDataContext: {
|
|
304
|
-
userId: 'user-456',
|
|
305
|
-
department: 'Engineering'
|
|
306
|
-
}
|
|
307
|
-
});
|
|
308
|
-
|
|
309
|
-
// Open AI Prompt test harness
|
|
310
|
-
const dialogRef = this.testHarnessService.openPromptTestHarness({
|
|
311
|
-
promptId: 'prompt-789',
|
|
312
|
-
selectedModelId: 'gpt-4',
|
|
313
|
-
initialTemplateVariables: {
|
|
314
|
-
name: 'Alice',
|
|
315
|
-
context: 'Customer support inquiry'
|
|
316
|
-
}
|
|
317
|
-
});
|
|
318
|
-
|
|
319
|
-
// Convenience methods
|
|
320
|
-
await this.testHarnessService.openAgentById('agent-123');
|
|
321
|
-
await this.testHarnessService.openPromptById('prompt-456');
|
|
322
|
-
```
|
|
323
|
-
|
|
324
|
-
### Enhanced AI Agent Form
|
|
325
|
-
|
|
326
|
-
The AI Agent form (`AIAgentFormComponentExtended`) includes integrated test harness access:
|
|
327
|
-
|
|
328
|
-
**Features:**
|
|
329
|
-
- **Built-in Test Button**: Direct access to test harness from agent form
|
|
330
|
-
- **Related Entity Management**: View sub-agents, prompts, actions, and execution history
|
|
331
|
-
- **Status Indicators**: Visual status badges and execution mode icons
|
|
332
|
-
- **Navigation Support**: Links to related entities
|
|
333
|
-
- **Execution History**: Recent runs with timing and status information
|
|
334
|
-
|
|
335
|
-
**Enhanced Capabilities:**
|
|
336
|
-
```typescript
|
|
337
|
-
// Open test harness from form
|
|
338
|
-
this.openTestHarness(); // Validates agent is saved first
|
|
339
|
-
|
|
340
|
-
// View execution status
|
|
341
|
-
this.getExecutionStatusIcon(status); // Returns appropriate FontAwesome icon
|
|
342
|
-
this.getExecutionStatusColor(status); // Returns status color
|
|
343
|
-
|
|
344
|
-
// Format timing information
|
|
345
|
-
this.formatExecutionTime(milliseconds); // Human-readable time format
|
|
346
|
-
```
|
|
347
|
-
|
|
348
|
-
### Conversation Management
|
|
349
|
-
|
|
350
|
-
Both test harnesses include comprehensive conversation management:
|
|
351
|
-
|
|
352
|
-
**Features:**
|
|
353
|
-
- **Auto-Save**: Conversations automatically save during active sessions
|
|
354
|
-
- **Manual Save**: Save conversations with custom names
|
|
355
|
-
- **Load/Restore**: Restore complete conversation state including variables
|
|
356
|
-
- **Export/Import**: JSON-based conversation portability
|
|
357
|
-
- **Storage Limits**: Automatic cleanup (50 conversation limit)
|
|
358
|
-
|
|
359
|
-
**Export Format:**
|
|
360
|
-
```json
|
|
361
|
-
{
|
|
362
|
-
"agent": {
|
|
363
|
-
"id": "agent-123",
|
|
364
|
-
"name": "Customer Service Agent",
|
|
365
|
-
"description": "Handles customer inquiries"
|
|
366
|
-
},
|
|
367
|
-
"messages": [...],
|
|
368
|
-
"dataContext": {
|
|
369
|
-
"userId": "user-456",
|
|
370
|
-
"department": "Support"
|
|
371
|
-
},
|
|
372
|
-
"templateData": {
|
|
373
|
-
"customerName": "John Doe"
|
|
374
|
-
},
|
|
375
|
-
"exportedAt": "2024-01-15T10:30:00.000Z"
|
|
376
|
-
}
|
|
377
|
-
```
|
|
378
|
-
|
|
379
|
-
### Content Rendering System
|
|
380
|
-
|
|
381
|
-
Advanced content formatting with automatic type detection:
|
|
382
|
-
|
|
383
|
-
**Supported Formats:**
|
|
384
|
-
- **Markdown**: Headers, lists, code blocks, links, emphasis
|
|
385
|
-
- **JSON**: Syntax highlighting and pretty formatting
|
|
386
|
-
- **Plain Text**: Clean text rendering with line breaks
|
|
387
|
-
|
|
388
|
-
**Content Type Detection:**
|
|
389
|
-
```typescript
|
|
390
|
-
// Automatically detects content type
|
|
391
|
-
const contentType = this.detectContentType(content);
|
|
392
|
-
// Returns: 'markdown' | 'json' | 'text'
|
|
393
|
-
|
|
394
|
-
// Renders content appropriately
|
|
395
|
-
const safeHtml = this.getFormattedContent(message);
|
|
396
|
-
```
|
|
397
|
-
|
|
398
|
-
### Integration Points
|
|
399
|
-
|
|
400
|
-
The test harness system integrates seamlessly with:
|
|
401
|
-
|
|
402
|
-
- **MemberJunction Entity System**: Uses proper entity loading patterns
|
|
403
|
-
- **GraphQL Data Provider**: Executes agents and prompts via GraphQL mutations
|
|
404
|
-
- **Notification Service**: User feedback for actions and errors
|
|
405
|
-
- **LocalStorage**: Conversation persistence across sessions
|
|
406
|
-
- **Kendo UI Dialogs**: Professional modal interfaces
|
|
407
220
|
|
|
408
221
|
## Notes
|
|
409
222
|
|
|
223
|
+
|
|
410
224
|
- Form components are dynamically instantiated at runtime based on entity names
|
|
411
225
|
- Custom loader functions are used to prevent tree-shaking in production builds
|
|
412
226
|
- The package is designed to work with the MemberJunction Explorer application
|
|
@@ -420,7 +234,6 @@ The test harness system integrates seamlessly with:
|
|
|
420
234
|
- @angular/forms
|
|
421
235
|
- @memberjunction/core
|
|
422
236
|
- @memberjunction/core-entities
|
|
423
|
-
- @memberjunction/ng-explorer-core
|
|
424
237
|
- @memberjunction/ng-base-forms
|
|
425
238
|
|
|
426
239
|
### UI Component Dependencies
|
|
@@ -439,21 +252,3 @@ The test harness system integrates seamlessly with:
|
|
|
439
252
|
- @memberjunction/ng-notifications
|
|
440
253
|
- @memberjunction/graphql-dataprovider
|
|
441
254
|
|
|
442
|
-
### Test Harness Components
|
|
443
|
-
|
|
444
|
-
The test harness system introduces several new components and services:
|
|
445
|
-
|
|
446
|
-
| Component/Service | Purpose |
|
|
447
|
-
|------------------|---------|
|
|
448
|
-
| `AIAgentTestHarnessComponent` | Interactive chat interface for testing AI agents |
|
|
449
|
-
| `AIPromptTestHarnessComponent` | Template variable testing for AI prompts |
|
|
450
|
-
| `AIAgentTestHarnessDialogComponent` | Modal dialog wrapper for agent testing |
|
|
451
|
-
| `AIPromptTestHarnessDialogComponent` | Modal dialog wrapper for prompt testing |
|
|
452
|
-
| `TestHarnessDialogService` | Centralized service for opening test harness dialogs |
|
|
453
|
-
| `AIAgentFormComponentExtended` | Enhanced AI agent form with integrated test harness |
|
|
454
|
-
|
|
455
|
-
### New Dependencies Added for Test Harness:
|
|
456
|
-
- **Angular DomSanitizer**: Safe HTML rendering for formatted content
|
|
457
|
-
- **RxJS Subjects**: Component lifecycle and event management
|
|
458
|
-
- **LocalStorage**: Conversation persistence across sessions
|
|
459
|
-
- **File API**: Import/export functionality for conversations
|
|
@@ -4,6 +4,9 @@ import { ActionEntity, AIAgentEntity, AIAgentLearningCycleEntity, AIAgentNoteEnt
|
|
|
4
4
|
import { AIAgentFormComponent } from '../../generated/Entities/AIAgent/aiagent.form.component';
|
|
5
5
|
import { DialogService } from '@progress/kendo-angular-dialog';
|
|
6
6
|
import { SharedService } from '@memberjunction/ng-shared';
|
|
7
|
+
import { NewAgentDialogService } from './new-agent-dialog.service';
|
|
8
|
+
import { ActionGalleryDialogService } from '@memberjunction/ng-action-gallery';
|
|
9
|
+
import { AITestHarnessDialogService } from '@memberjunction/ng-ai-test-harness';
|
|
7
10
|
import * as i0 from "@angular/core";
|
|
8
11
|
/**
|
|
9
12
|
* Enhanced AI Agent form component that extends the auto-generated base form
|
|
@@ -39,10 +42,11 @@ export declare class AIAgentFormComponentExtended extends AIAgentFormComponent i
|
|
|
39
42
|
protected sharedService: SharedService;
|
|
40
43
|
private dialogService;
|
|
41
44
|
private viewContainerRef;
|
|
45
|
+
private newAgentDialogService;
|
|
46
|
+
private actionGalleryService;
|
|
47
|
+
private testHarnessService;
|
|
42
48
|
/** The AI Agent entity being edited */
|
|
43
49
|
record: AIAgentEntity;
|
|
44
|
-
/** Whether the test harness is currently visible */
|
|
45
|
-
showTestHarness: boolean;
|
|
46
50
|
/** Number of sub-agents under this agent */
|
|
47
51
|
subAgentCount: number;
|
|
48
52
|
/** Number of prompts associated with this agent */
|
|
@@ -67,7 +71,11 @@ export declare class AIAgentFormComponentExtended extends AIAgentFormComponent i
|
|
|
67
71
|
agentNotes: AIAgentNoteEntity[];
|
|
68
72
|
/** Array of recent execution records for history display */
|
|
69
73
|
recentExecutions: AIAgentRunEntity[];
|
|
70
|
-
|
|
74
|
+
/** Track which execution cards are expanded */
|
|
75
|
+
expandedExecutions: {
|
|
76
|
+
[key: string]: boolean;
|
|
77
|
+
};
|
|
78
|
+
constructor(elementRef: ElementRef, sharedService: SharedService, router: Router, route: ActivatedRoute, cdr: ChangeDetectorRef, dialogService: DialogService, viewContainerRef: ViewContainerRef, newAgentDialogService: NewAgentDialogService, actionGalleryService: ActionGalleryDialogService, testHarnessService: AITestHarnessDialogService);
|
|
71
79
|
/**
|
|
72
80
|
* Component initialization. Calls parent initialization and loads related entity data
|
|
73
81
|
* if an agent record is already available.
|
|
@@ -97,7 +105,6 @@ export declare class AIAgentFormComponentExtended extends AIAgentFormComponent i
|
|
|
97
105
|
* Updates the component state when the test harness is opened or closed.
|
|
98
106
|
* @param isVisible - Whether the test harness is currently visible
|
|
99
107
|
*/
|
|
100
|
-
onTestHarnessVisibilityChanged(isVisible: boolean): void;
|
|
101
108
|
/**
|
|
102
109
|
* Gets the count of sub-agents
|
|
103
110
|
*/
|
|
@@ -123,7 +130,7 @@ export declare class AIAgentFormComponentExtended extends AIAgentFormComponent i
|
|
|
123
130
|
*/
|
|
124
131
|
addPrompt(): Promise<void>;
|
|
125
132
|
/**
|
|
126
|
-
* Opens the action
|
|
133
|
+
* Opens the enhanced action gallery for selecting actions
|
|
127
134
|
*/
|
|
128
135
|
configureActions(): Promise<void>;
|
|
129
136
|
/**
|
|
@@ -151,6 +158,22 @@ export declare class AIAgentFormComponentExtended extends AIAgentFormComponent i
|
|
|
151
158
|
* Navigates to a related entity
|
|
152
159
|
*/
|
|
153
160
|
navigateToEntity(entityName: string, recordId: string): void;
|
|
161
|
+
/**
|
|
162
|
+
* Toggles the expanded state of an execution card
|
|
163
|
+
*/
|
|
164
|
+
toggleExecutionExpanded(executionId: string): void;
|
|
165
|
+
/**
|
|
166
|
+
* Opens the full execution record in a new view
|
|
167
|
+
*/
|
|
168
|
+
openExecutionRecord(executionId: string): void;
|
|
169
|
+
/**
|
|
170
|
+
* Gets a preview of the execution result for collapsed view
|
|
171
|
+
*/
|
|
172
|
+
getExecutionResultPreview(execution: AIAgentRunEntity): string;
|
|
173
|
+
/**
|
|
174
|
+
* Gets the full execution result message for expanded view
|
|
175
|
+
*/
|
|
176
|
+
getExecutionResultMessage(execution: AIAgentRunEntity): string;
|
|
154
177
|
/**
|
|
155
178
|
* Refreshes the related data
|
|
156
179
|
*/
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ai-agent-form.component.d.ts","sourceRoot":"","sources":["../../../../src/lib/custom/AIAgents/ai-agent-form.component.ts"],"names":[],"mappings":"AAAA,OAAO,EAAa,MAAM,EAAE,gBAAgB,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,eAAe,CAAC;AACnG,O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