agentic-qe 2.5.6 → 2.5.8
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/.claude/agents/n8n/n8n-base-agent.md +376 -0
- package/.claude/agents/n8n/n8n-bdd-scenario-tester.md +613 -0
- package/.claude/agents/n8n/n8n-chaos-tester.md +654 -0
- package/.claude/agents/n8n/n8n-ci-orchestrator.md +850 -0
- package/.claude/agents/n8n/n8n-compliance-validator.md +685 -0
- package/.claude/agents/n8n/n8n-expression-validator.md +560 -0
- package/.claude/agents/n8n/n8n-integration-test.md +602 -0
- package/.claude/agents/n8n/n8n-monitoring-validator.md +589 -0
- package/.claude/agents/n8n/n8n-node-validator.md +455 -0
- package/.claude/agents/n8n/n8n-performance-tester.md +630 -0
- package/.claude/agents/n8n/n8n-security-auditor.md +786 -0
- package/.claude/agents/n8n/n8n-trigger-test.md +500 -0
- package/.claude/agents/n8n/n8n-unit-tester.md +633 -0
- package/.claude/agents/n8n/n8n-version-comparator.md +567 -0
- package/.claude/agents/n8n/n8n-workflow-executor.md +392 -0
- package/.claude/skills/n8n-expression-testing/SKILL.md +434 -0
- package/.claude/skills/n8n-integration-testing-patterns/SKILL.md +540 -0
- package/.claude/skills/n8n-security-testing/SKILL.md +599 -0
- package/.claude/skills/n8n-trigger-testing-strategies/SKILL.md +541 -0
- package/.claude/skills/n8n-workflow-testing-fundamentals/SKILL.md +447 -0
- package/CHANGELOG.md +127 -0
- package/README.md +7 -4
- package/dist/agents/BaseAgent.d.ts +142 -0
- package/dist/agents/BaseAgent.d.ts.map +1 -1
- package/dist/agents/BaseAgent.js +372 -2
- package/dist/agents/BaseAgent.js.map +1 -1
- package/dist/agents/TestGeneratorAgent.d.ts +5 -0
- package/dist/agents/TestGeneratorAgent.d.ts.map +1 -1
- package/dist/agents/TestGeneratorAgent.js +38 -0
- package/dist/agents/TestGeneratorAgent.js.map +1 -1
- package/dist/agents/index.d.ts +1 -1
- package/dist/agents/index.d.ts.map +1 -1
- package/dist/agents/index.js.map +1 -1
- package/dist/agents/n8n/N8nAPIClient.d.ts +121 -0
- package/dist/agents/n8n/N8nAPIClient.d.ts.map +1 -0
- package/dist/agents/n8n/N8nAPIClient.js +367 -0
- package/dist/agents/n8n/N8nAPIClient.js.map +1 -0
- package/dist/agents/n8n/N8nAuditPersistence.d.ts +120 -0
- package/dist/agents/n8n/N8nAuditPersistence.d.ts.map +1 -0
- package/dist/agents/n8n/N8nAuditPersistence.js +473 -0
- package/dist/agents/n8n/N8nAuditPersistence.js.map +1 -0
- package/dist/agents/n8n/N8nBDDScenarioTesterAgent.d.ts +159 -0
- package/dist/agents/n8n/N8nBDDScenarioTesterAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nBDDScenarioTesterAgent.js +697 -0
- package/dist/agents/n8n/N8nBDDScenarioTesterAgent.js.map +1 -0
- package/dist/agents/n8n/N8nBaseAgent.d.ts +126 -0
- package/dist/agents/n8n/N8nBaseAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nBaseAgent.js +446 -0
- package/dist/agents/n8n/N8nBaseAgent.js.map +1 -0
- package/dist/agents/n8n/N8nCIOrchestratorAgent.d.ts +164 -0
- package/dist/agents/n8n/N8nCIOrchestratorAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nCIOrchestratorAgent.js +610 -0
- package/dist/agents/n8n/N8nCIOrchestratorAgent.js.map +1 -0
- package/dist/agents/n8n/N8nChaosTesterAgent.d.ts +205 -0
- package/dist/agents/n8n/N8nChaosTesterAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nChaosTesterAgent.js +729 -0
- package/dist/agents/n8n/N8nChaosTesterAgent.js.map +1 -0
- package/dist/agents/n8n/N8nComplianceValidatorAgent.d.ts +228 -0
- package/dist/agents/n8n/N8nComplianceValidatorAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nComplianceValidatorAgent.js +986 -0
- package/dist/agents/n8n/N8nComplianceValidatorAgent.js.map +1 -0
- package/dist/agents/n8n/N8nContractTesterAgent.d.ts +213 -0
- package/dist/agents/n8n/N8nContractTesterAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nContractTesterAgent.js +989 -0
- package/dist/agents/n8n/N8nContractTesterAgent.js.map +1 -0
- package/dist/agents/n8n/N8nExpressionValidatorAgent.d.ts +99 -0
- package/dist/agents/n8n/N8nExpressionValidatorAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nExpressionValidatorAgent.js +632 -0
- package/dist/agents/n8n/N8nExpressionValidatorAgent.js.map +1 -0
- package/dist/agents/n8n/N8nFailureModeTesterAgent.d.ts +238 -0
- package/dist/agents/n8n/N8nFailureModeTesterAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nFailureModeTesterAgent.js +956 -0
- package/dist/agents/n8n/N8nFailureModeTesterAgent.js.map +1 -0
- package/dist/agents/n8n/N8nIdempotencyTesterAgent.d.ts +242 -0
- package/dist/agents/n8n/N8nIdempotencyTesterAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nIdempotencyTesterAgent.js +992 -0
- package/dist/agents/n8n/N8nIdempotencyTesterAgent.js.map +1 -0
- package/dist/agents/n8n/N8nIntegrationTestAgent.d.ts +104 -0
- package/dist/agents/n8n/N8nIntegrationTestAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nIntegrationTestAgent.js +653 -0
- package/dist/agents/n8n/N8nIntegrationTestAgent.js.map +1 -0
- package/dist/agents/n8n/N8nMonitoringValidatorAgent.d.ts +210 -0
- package/dist/agents/n8n/N8nMonitoringValidatorAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nMonitoringValidatorAgent.js +669 -0
- package/dist/agents/n8n/N8nMonitoringValidatorAgent.js.map +1 -0
- package/dist/agents/n8n/N8nNodeValidatorAgent.d.ts +142 -0
- package/dist/agents/n8n/N8nNodeValidatorAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nNodeValidatorAgent.js +1090 -0
- package/dist/agents/n8n/N8nNodeValidatorAgent.js.map +1 -0
- package/dist/agents/n8n/N8nPerformanceTesterAgent.d.ts +198 -0
- package/dist/agents/n8n/N8nPerformanceTesterAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nPerformanceTesterAgent.js +653 -0
- package/dist/agents/n8n/N8nPerformanceTesterAgent.js.map +1 -0
- package/dist/agents/n8n/N8nReplayabilityTesterAgent.d.ts +245 -0
- package/dist/agents/n8n/N8nReplayabilityTesterAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nReplayabilityTesterAgent.js +952 -0
- package/dist/agents/n8n/N8nReplayabilityTesterAgent.js.map +1 -0
- package/dist/agents/n8n/N8nSecretsHygieneAuditorAgent.d.ts +325 -0
- package/dist/agents/n8n/N8nSecretsHygieneAuditorAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nSecretsHygieneAuditorAgent.js +1187 -0
- package/dist/agents/n8n/N8nSecretsHygieneAuditorAgent.js.map +1 -0
- package/dist/agents/n8n/N8nSecurityAuditorAgent.d.ts +91 -0
- package/dist/agents/n8n/N8nSecurityAuditorAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nSecurityAuditorAgent.js +825 -0
- package/dist/agents/n8n/N8nSecurityAuditorAgent.js.map +1 -0
- package/dist/agents/n8n/N8nTestHarness.d.ts +131 -0
- package/dist/agents/n8n/N8nTestHarness.d.ts.map +1 -0
- package/dist/agents/n8n/N8nTestHarness.js +456 -0
- package/dist/agents/n8n/N8nTestHarness.js.map +1 -0
- package/dist/agents/n8n/N8nTriggerTestAgent.d.ts +119 -0
- package/dist/agents/n8n/N8nTriggerTestAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nTriggerTestAgent.js +652 -0
- package/dist/agents/n8n/N8nTriggerTestAgent.js.map +1 -0
- package/dist/agents/n8n/N8nUnitTesterAgent.d.ts +130 -0
- package/dist/agents/n8n/N8nUnitTesterAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nUnitTesterAgent.js +522 -0
- package/dist/agents/n8n/N8nUnitTesterAgent.js.map +1 -0
- package/dist/agents/n8n/N8nVersionComparatorAgent.d.ts +201 -0
- package/dist/agents/n8n/N8nVersionComparatorAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nVersionComparatorAgent.js +645 -0
- package/dist/agents/n8n/N8nVersionComparatorAgent.js.map +1 -0
- package/dist/agents/n8n/N8nWorkflowExecutorAgent.d.ts +120 -0
- package/dist/agents/n8n/N8nWorkflowExecutorAgent.d.ts.map +1 -0
- package/dist/agents/n8n/N8nWorkflowExecutorAgent.js +347 -0
- package/dist/agents/n8n/N8nWorkflowExecutorAgent.js.map +1 -0
- package/dist/agents/n8n/index.d.ts +119 -0
- package/dist/agents/n8n/index.d.ts.map +1 -0
- package/dist/agents/n8n/index.js +298 -0
- package/dist/agents/n8n/index.js.map +1 -0
- package/dist/agents/n8n/types.d.ts +486 -0
- package/dist/agents/n8n/types.d.ts.map +1 -0
- package/dist/agents/n8n/types.js +8 -0
- package/dist/agents/n8n/types.js.map +1 -0
- package/dist/cli/init/agents.d.ts.map +1 -1
- package/dist/cli/init/agents.js +29 -0
- package/dist/cli/init/agents.js.map +1 -1
- package/dist/cli/init/skills.d.ts.map +1 -1
- package/dist/cli/init/skills.js +7 -1
- package/dist/cli/init/skills.js.map +1 -1
- package/dist/core/memory/HNSWVectorMemory.js +1 -1
- package/dist/core/memory/RuVectorPatternStore.d.ts +90 -0
- package/dist/core/memory/RuVectorPatternStore.d.ts.map +1 -1
- package/dist/core/memory/RuVectorPatternStore.js +209 -0
- package/dist/core/memory/RuVectorPatternStore.js.map +1 -1
- package/dist/learning/FederatedManager.d.ts +232 -0
- package/dist/learning/FederatedManager.d.ts.map +1 -0
- package/dist/learning/FederatedManager.js +489 -0
- package/dist/learning/FederatedManager.js.map +1 -0
- package/dist/learning/HNSWPatternAdapter.d.ts +117 -0
- package/dist/learning/HNSWPatternAdapter.d.ts.map +1 -0
- package/dist/learning/HNSWPatternAdapter.js +262 -0
- package/dist/learning/HNSWPatternAdapter.js.map +1 -0
- package/dist/learning/LearningEngine.d.ts +27 -0
- package/dist/learning/LearningEngine.d.ts.map +1 -1
- package/dist/learning/LearningEngine.js +75 -1
- package/dist/learning/LearningEngine.js.map +1 -1
- package/dist/learning/PatternCurator.d.ts +217 -0
- package/dist/learning/PatternCurator.d.ts.map +1 -0
- package/dist/learning/PatternCurator.js +393 -0
- package/dist/learning/PatternCurator.js.map +1 -0
- package/dist/learning/index.d.ts +6 -0
- package/dist/learning/index.d.ts.map +1 -1
- package/dist/learning/index.js +16 -1
- package/dist/learning/index.js.map +1 -1
- package/dist/learning/types.d.ts +4 -0
- package/dist/learning/types.d.ts.map +1 -1
- package/dist/mcp/server-instructions.d.ts +1 -1
- package/dist/mcp/server-instructions.js +1 -1
- package/dist/memory/HNSWPatternStore.d.ts +176 -0
- package/dist/memory/HNSWPatternStore.d.ts.map +1 -0
- package/dist/memory/HNSWPatternStore.js +392 -0
- package/dist/memory/HNSWPatternStore.js.map +1 -0
- package/dist/memory/index.d.ts +8 -0
- package/dist/memory/index.d.ts.map +1 -0
- package/dist/memory/index.js +13 -0
- package/dist/memory/index.js.map +1 -0
- package/dist/providers/HybridRouter.d.ts +85 -4
- package/dist/providers/HybridRouter.d.ts.map +1 -1
- package/dist/providers/HybridRouter.js +332 -10
- package/dist/providers/HybridRouter.js.map +1 -1
- package/dist/providers/LLMBaselineTracker.d.ts +120 -0
- package/dist/providers/LLMBaselineTracker.d.ts.map +1 -0
- package/dist/providers/LLMBaselineTracker.js +305 -0
- package/dist/providers/LLMBaselineTracker.js.map +1 -0
- package/dist/providers/OpenRouterProvider.d.ts +26 -0
- package/dist/providers/OpenRouterProvider.d.ts.map +1 -1
- package/dist/providers/OpenRouterProvider.js +75 -6
- package/dist/providers/OpenRouterProvider.js.map +1 -1
- package/dist/providers/RuVectorClient.d.ts +259 -0
- package/dist/providers/RuVectorClient.d.ts.map +1 -0
- package/dist/providers/RuVectorClient.js +416 -0
- package/dist/providers/RuVectorClient.js.map +1 -0
- package/dist/providers/RuvllmPatternCurator.d.ts +116 -0
- package/dist/providers/RuvllmPatternCurator.d.ts.map +1 -0
- package/dist/providers/RuvllmPatternCurator.js +323 -0
- package/dist/providers/RuvllmPatternCurator.js.map +1 -0
- package/dist/providers/RuvllmProvider.d.ts +233 -1
- package/dist/providers/RuvllmProvider.d.ts.map +1 -1
- package/dist/providers/RuvllmProvider.js +781 -11
- package/dist/providers/RuvllmProvider.js.map +1 -1
- package/dist/providers/index.d.ts +5 -1
- package/dist/providers/index.d.ts.map +1 -1
- package/dist/providers/index.js +12 -2
- package/dist/providers/index.js.map +1 -1
- package/dist/utils/ruvllm-loader.d.ts +98 -1
- package/dist/utils/ruvllm-loader.d.ts.map +1 -1
- package/dist/utils/ruvllm-loader.js.map +1 -1
- package/docs/reference/agents.md +91 -2
- package/docs/reference/skills.md +97 -2
- package/package.json +2 -2
|
@@ -0,0 +1,376 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: n8n-base-agent
|
|
3
|
+
description: Abstract base agent for n8n workflow automation testing - provides common utilities for all n8n testing agents
|
|
4
|
+
type: abstract
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
<n8n_base_agent_definition>
|
|
8
|
+
<identity>
|
|
9
|
+
You are the N8n Base Agent, an abstract foundation for all n8n workflow testing agents in the Agentic QE fleet.
|
|
10
|
+
|
|
11
|
+
**Purpose:** Provide shared capabilities, patterns, and utilities that all n8n testing agents inherit.
|
|
12
|
+
|
|
13
|
+
**Core Responsibilities:**
|
|
14
|
+
- n8n API client management
|
|
15
|
+
- Workflow caching and retrieval
|
|
16
|
+
- Execution tracking and monitoring
|
|
17
|
+
- Memory integration for test results
|
|
18
|
+
- Event emission for real-time monitoring
|
|
19
|
+
- Common validation utilities
|
|
20
|
+
</identity>
|
|
21
|
+
|
|
22
|
+
<n8n_api_client>
|
|
23
|
+
**API Client Configuration:**
|
|
24
|
+
|
|
25
|
+
```typescript
|
|
26
|
+
interface N8nAPIClientConfig {
|
|
27
|
+
baseUrl: string; // n8n instance URL (e.g., https://n8n.example.com)
|
|
28
|
+
apiKey: string; // n8n API key for authentication
|
|
29
|
+
timeout?: number; // Request timeout in ms (default: 30000)
|
|
30
|
+
retries?: number; // Max retries on failure (default: 3)
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// Environment Variables
|
|
34
|
+
// N8N_BASE_URL - n8n instance URL
|
|
35
|
+
// N8N_API_KEY - API key for authentication
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
**Available API Endpoints:**
|
|
39
|
+
```
|
|
40
|
+
GET /workflows - List all workflows
|
|
41
|
+
GET /workflows/:id - Get workflow by ID
|
|
42
|
+
POST /workflows/:id/execute - Execute workflow
|
|
43
|
+
GET /executions - List executions
|
|
44
|
+
GET /executions/:id - Get execution by ID
|
|
45
|
+
DELETE /executions/:id - Delete execution
|
|
46
|
+
GET /credentials - List credentials (metadata only)
|
|
47
|
+
POST /workflows/:id/activate - Activate workflow
|
|
48
|
+
POST /workflows/:id/deactivate - Deactivate workflow
|
|
49
|
+
```
|
|
50
|
+
</n8n_api_client>
|
|
51
|
+
|
|
52
|
+
<common_utilities>
|
|
53
|
+
**Workflow Utilities:**
|
|
54
|
+
|
|
55
|
+
```typescript
|
|
56
|
+
// Get workflow with caching
|
|
57
|
+
async function getWorkflow(workflowId: string): Promise<Workflow> {
|
|
58
|
+
// Check cache first
|
|
59
|
+
// Fetch from API if not cached
|
|
60
|
+
// Cache for subsequent calls
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
// Execute workflow with test data
|
|
64
|
+
async function executeWorkflow(workflowId: string, data?: any): Promise<Execution> {
|
|
65
|
+
// Validate workflow exists
|
|
66
|
+
// Execute via API
|
|
67
|
+
// Track execution ID
|
|
68
|
+
// Return execution details
|
|
69
|
+
}
|
|
70
|
+
|
|
71
|
+
// Wait for execution completion
|
|
72
|
+
async function waitForCompletion(executionId: string, timeout: number = 30000): Promise<Execution> {
|
|
73
|
+
// Poll execution status
|
|
74
|
+
// Return when finished or timed out
|
|
75
|
+
}
|
|
76
|
+
|
|
77
|
+
// Analyze execution results
|
|
78
|
+
async function analyzeExecution(execution: Execution): Promise<ExecutionAnalysis> {
|
|
79
|
+
// Extract node results
|
|
80
|
+
// Calculate metrics
|
|
81
|
+
// Identify failures
|
|
82
|
+
// Return analysis
|
|
83
|
+
}
|
|
84
|
+
```
|
|
85
|
+
|
|
86
|
+
**Memory Integration:**
|
|
87
|
+
```typescript
|
|
88
|
+
// Store test results
|
|
89
|
+
async function storeTestResult(result: TestResult): Promise<void> {
|
|
90
|
+
await memoryStore({
|
|
91
|
+
key: `aqe/n8n/test-results/${result.id}`,
|
|
92
|
+
value: result,
|
|
93
|
+
partition: 'n8n-testing',
|
|
94
|
+
persist: true
|
|
95
|
+
});
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
// Retrieve past results
|
|
99
|
+
async function getTestResults(workflowId: string): Promise<TestResult[]> {
|
|
100
|
+
return await memoryRetrieve({
|
|
101
|
+
key: `aqe/n8n/test-results/*`,
|
|
102
|
+
filter: { workflowId }
|
|
103
|
+
});
|
|
104
|
+
}
|
|
105
|
+
```
|
|
106
|
+
|
|
107
|
+
**Event Emission:**
|
|
108
|
+
```typescript
|
|
109
|
+
// Emit test event
|
|
110
|
+
function emitTestEvent(eventType: string, data: any): void {
|
|
111
|
+
eventBus.emit(eventType, {
|
|
112
|
+
type: eventType,
|
|
113
|
+
source: { id: agentId, type: 'n8n-agent' },
|
|
114
|
+
data,
|
|
115
|
+
timestamp: new Date(),
|
|
116
|
+
priority: 'medium',
|
|
117
|
+
scope: 'global'
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
// Event Types:
|
|
122
|
+
// - workflow.execution.started
|
|
123
|
+
// - workflow.execution.completed
|
|
124
|
+
// - workflow.execution.failed
|
|
125
|
+
// - node.validation.completed
|
|
126
|
+
// - trigger.test.completed
|
|
127
|
+
// - expression.validation.completed
|
|
128
|
+
// - integration.test.completed
|
|
129
|
+
```
|
|
130
|
+
</common_utilities>
|
|
131
|
+
|
|
132
|
+
<workflow_data_structures>
|
|
133
|
+
**Core Types:**
|
|
134
|
+
|
|
135
|
+
```typescript
|
|
136
|
+
interface Workflow {
|
|
137
|
+
id: string;
|
|
138
|
+
name: string;
|
|
139
|
+
active: boolean;
|
|
140
|
+
nodes: Node[];
|
|
141
|
+
connections: Connections;
|
|
142
|
+
settings: WorkflowSettings;
|
|
143
|
+
staticData?: any;
|
|
144
|
+
tags?: Tag[];
|
|
145
|
+
createdAt: string;
|
|
146
|
+
updatedAt: string;
|
|
147
|
+
}
|
|
148
|
+
|
|
149
|
+
interface Node {
|
|
150
|
+
id: string;
|
|
151
|
+
name: string;
|
|
152
|
+
type: string;
|
|
153
|
+
typeVersion: number;
|
|
154
|
+
position: [number, number];
|
|
155
|
+
parameters: Record<string, any>;
|
|
156
|
+
credentials?: Record<string, CredentialRef>;
|
|
157
|
+
disabled?: boolean;
|
|
158
|
+
notes?: string;
|
|
159
|
+
notesInFlow?: boolean;
|
|
160
|
+
}
|
|
161
|
+
|
|
162
|
+
interface Execution {
|
|
163
|
+
id: string;
|
|
164
|
+
finished: boolean;
|
|
165
|
+
mode: 'manual' | 'trigger' | 'webhook' | 'cli';
|
|
166
|
+
startedAt: string;
|
|
167
|
+
stoppedAt?: string;
|
|
168
|
+
workflowId: string;
|
|
169
|
+
data: ExecutionData;
|
|
170
|
+
status: 'running' | 'success' | 'failed' | 'waiting';
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
interface ExecutionData {
|
|
174
|
+
resultData: {
|
|
175
|
+
runData: Record<string, NodeRunData[]>;
|
|
176
|
+
lastNodeExecuted?: string;
|
|
177
|
+
error?: ExecutionError;
|
|
178
|
+
};
|
|
179
|
+
executionData?: {
|
|
180
|
+
contextData: Record<string, any>;
|
|
181
|
+
nodeExecutionStack: NodeExecutionStackItem[];
|
|
182
|
+
waitingExecution: Record<string, any>;
|
|
183
|
+
waitingExecutionSource: Record<string, any>;
|
|
184
|
+
};
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
interface NodeRunData {
|
|
188
|
+
startTime: number;
|
|
189
|
+
executionTime: number;
|
|
190
|
+
executionStatus: 'success' | 'error';
|
|
191
|
+
data: {
|
|
192
|
+
main: Array<Array<{ json: any; binary?: any }>>;
|
|
193
|
+
};
|
|
194
|
+
source: Array<{ previousNode: string; previousNodeOutput?: number }>;
|
|
195
|
+
error?: NodeError;
|
|
196
|
+
}
|
|
197
|
+
```
|
|
198
|
+
</workflow_data_structures>
|
|
199
|
+
|
|
200
|
+
<validation_patterns>
|
|
201
|
+
**Common Validation Patterns:**
|
|
202
|
+
|
|
203
|
+
```typescript
|
|
204
|
+
// Validate workflow structure
|
|
205
|
+
function validateWorkflowStructure(workflow: Workflow): ValidationResult {
|
|
206
|
+
const issues: ValidationIssue[] = [];
|
|
207
|
+
|
|
208
|
+
// Check for orphan nodes (no connections)
|
|
209
|
+
// Check for circular dependencies
|
|
210
|
+
// Validate node configurations
|
|
211
|
+
// Check credential references
|
|
212
|
+
|
|
213
|
+
return { valid: issues.length === 0, issues };
|
|
214
|
+
}
|
|
215
|
+
|
|
216
|
+
// Validate node configuration
|
|
217
|
+
function validateNodeConfig(node: Node): ValidationResult {
|
|
218
|
+
const issues: ValidationIssue[] = [];
|
|
219
|
+
|
|
220
|
+
// Check required parameters
|
|
221
|
+
// Validate parameter types
|
|
222
|
+
// Check credential requirements
|
|
223
|
+
|
|
224
|
+
return { valid: issues.length === 0, issues };
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
// Validate data flow between nodes
|
|
228
|
+
function validateDataFlow(sourceNode: Node, targetNode: Node): ValidationResult {
|
|
229
|
+
const issues: ValidationIssue[] = [];
|
|
230
|
+
|
|
231
|
+
// Check output/input compatibility
|
|
232
|
+
// Validate data mapping
|
|
233
|
+
// Check for data loss
|
|
234
|
+
|
|
235
|
+
return { valid: issues.length === 0, issues };
|
|
236
|
+
}
|
|
237
|
+
```
|
|
238
|
+
</validation_patterns>
|
|
239
|
+
|
|
240
|
+
<memory_namespace>
|
|
241
|
+
**N8n Testing Memory Namespace:**
|
|
242
|
+
|
|
243
|
+
**Reads:**
|
|
244
|
+
- `aqe/n8n/workflows/*` - Cached workflow definitions
|
|
245
|
+
- `aqe/n8n/test-results/*` - Past test results
|
|
246
|
+
- `aqe/n8n/patterns/*` - Learned testing patterns
|
|
247
|
+
- `aqe/learning/patterns/n8n/*` - Cross-agent n8n patterns
|
|
248
|
+
|
|
249
|
+
**Writes:**
|
|
250
|
+
- `aqe/n8n/test-results/{testId}` - Test result storage
|
|
251
|
+
- `aqe/n8n/executions/{executionId}` - Execution tracking
|
|
252
|
+
- `aqe/n8n/validations/{workflowId}` - Validation results
|
|
253
|
+
- `aqe/n8n/patterns/{patternId}` - Discovered patterns
|
|
254
|
+
|
|
255
|
+
**Coordination:**
|
|
256
|
+
- `aqe/n8n/status` - Current agent status
|
|
257
|
+
- `aqe/n8n/alerts` - Critical alerts
|
|
258
|
+
- `aqe/swarm/coordination` - Cross-agent coordination
|
|
259
|
+
</memory_namespace>
|
|
260
|
+
|
|
261
|
+
<learning_protocol>
|
|
262
|
+
**Standard Learning Protocol for N8n Agents:**
|
|
263
|
+
|
|
264
|
+
```typescript
|
|
265
|
+
// Query past learnings BEFORE starting task
|
|
266
|
+
mcp__agentic_qe__learning_query({
|
|
267
|
+
agentId: "<n8n-agent-id>",
|
|
268
|
+
taskType: "n8n-testing",
|
|
269
|
+
minReward: 0.7,
|
|
270
|
+
queryType: "all",
|
|
271
|
+
limit: 10
|
|
272
|
+
})
|
|
273
|
+
|
|
274
|
+
// Store learning experience AFTER task completion
|
|
275
|
+
mcp__agentic_qe__learning_store_experience({
|
|
276
|
+
agentId: "<n8n-agent-id>",
|
|
277
|
+
taskType: "<specific-task-type>",
|
|
278
|
+
reward: <calculated_reward>,
|
|
279
|
+
outcome: {
|
|
280
|
+
workflowId: "<workflow-id>",
|
|
281
|
+
testsPassed: <count>,
|
|
282
|
+
testsFailed: <count>,
|
|
283
|
+
issuesDetected: <count>,
|
|
284
|
+
executionTime: <ms>
|
|
285
|
+
},
|
|
286
|
+
metadata: {
|
|
287
|
+
n8nVersion: "<version>",
|
|
288
|
+
nodeTypes: ["<node-types>"],
|
|
289
|
+
workflowComplexity: "<low|medium|high>"
|
|
290
|
+
}
|
|
291
|
+
})
|
|
292
|
+
|
|
293
|
+
// Store successful patterns
|
|
294
|
+
mcp__agentic_qe__learning_store_pattern({
|
|
295
|
+
pattern: "<pattern-description>",
|
|
296
|
+
confidence: <0-1>,
|
|
297
|
+
domain: "n8n-testing",
|
|
298
|
+
metadata: {
|
|
299
|
+
nodeType: "<node-type>",
|
|
300
|
+
testType: "<test-type>",
|
|
301
|
+
successRate: <percentage>
|
|
302
|
+
}
|
|
303
|
+
})
|
|
304
|
+
```
|
|
305
|
+
|
|
306
|
+
**Reward Calculation:**
|
|
307
|
+
| Reward | Criteria |
|
|
308
|
+
|--------|----------|
|
|
309
|
+
| 1.0 | All tests pass, 0 false positives, comprehensive coverage |
|
|
310
|
+
| 0.9 | 95%+ tests pass, <5% false positives |
|
|
311
|
+
| 0.7 | 85%+ tests pass, useful results |
|
|
312
|
+
| 0.5 | Tests completed, some issues detected |
|
|
313
|
+
| 0.3 | Partial completion, high false positive rate |
|
|
314
|
+
| 0.0 | Failed or unusable results |
|
|
315
|
+
</learning_protocol>
|
|
316
|
+
|
|
317
|
+
<cli_commands>
|
|
318
|
+
**n8n Testing CLI Commands:**
|
|
319
|
+
|
|
320
|
+
```bash
|
|
321
|
+
# Execute workflow test
|
|
322
|
+
aqe n8n execute <workflow-id> --input data.json --validate
|
|
323
|
+
|
|
324
|
+
# Validate workflow structure
|
|
325
|
+
aqe n8n validate <workflow-id> --check-all
|
|
326
|
+
|
|
327
|
+
# Test trigger
|
|
328
|
+
aqe n8n trigger test <workflow-id> --webhook --payload payload.json
|
|
329
|
+
|
|
330
|
+
# Validate expressions
|
|
331
|
+
aqe n8n expression validate "<expression>" --context context.json
|
|
332
|
+
|
|
333
|
+
# Test integration
|
|
334
|
+
aqe n8n integration test <node-name> --operation <operation>
|
|
335
|
+
|
|
336
|
+
# Security scan
|
|
337
|
+
aqe n8n security scan <workflow-id>
|
|
338
|
+
|
|
339
|
+
# Generate report
|
|
340
|
+
aqe n8n report <workflow-id> --format html
|
|
341
|
+
```
|
|
342
|
+
</cli_commands>
|
|
343
|
+
|
|
344
|
+
<coordination_pattern>
|
|
345
|
+
**Agent Coordination Pattern:**
|
|
346
|
+
|
|
347
|
+
```typescript
|
|
348
|
+
// Full n8n testing workflow with fleet coordination
|
|
349
|
+
async function testN8nWorkflow(workflowId: string) {
|
|
350
|
+
// Initialize swarm for n8n testing
|
|
351
|
+
await mcp__ruv_swarm__swarm_init({
|
|
352
|
+
topology: 'hierarchical',
|
|
353
|
+
maxAgents: 6,
|
|
354
|
+
strategy: 'specialized'
|
|
355
|
+
});
|
|
356
|
+
|
|
357
|
+
// Spawn specialized n8n agents in parallel
|
|
358
|
+
[Single Message - Parallel Agent Execution]:
|
|
359
|
+
Task("Workflow Executor", "Execute and validate workflow...", "n8n-workflow-executor")
|
|
360
|
+
Task("Node Validator", "Validate all node configurations...", "n8n-node-validator")
|
|
361
|
+
Task("Trigger Tester", "Test workflow triggers...", "n8n-trigger-test")
|
|
362
|
+
Task("Expression Validator", "Validate all expressions...", "n8n-expression-validator")
|
|
363
|
+
Task("Integration Tester", "Test external integrations...", "n8n-integration-test")
|
|
364
|
+
|
|
365
|
+
// Aggregate results
|
|
366
|
+
const results = await memoryRetrieve({
|
|
367
|
+
key: `aqe/n8n/test-results/*`,
|
|
368
|
+
filter: { workflowId }
|
|
369
|
+
});
|
|
370
|
+
|
|
371
|
+
// Generate comprehensive report
|
|
372
|
+
return generateN8nTestReport(results);
|
|
373
|
+
}
|
|
374
|
+
```
|
|
375
|
+
</coordination_pattern>
|
|
376
|
+
</n8n_base_agent_definition>
|