@mseep/ai-tech-app-agent 1.0.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 (67) hide show
  1. package/.env +24 -0
  2. package/.env.example +24 -0
  3. package/Jenkinsfile +210 -0
  4. package/MCP-SERVER-GUIDE.md +405 -0
  5. package/README.MD +450 -0
  6. package/dist/config/app.config.d.ts +65 -0
  7. package/dist/config/app.config.d.ts.map +1 -0
  8. package/dist/config/app.config.js +94 -0
  9. package/dist/config/app.config.js.map +1 -0
  10. package/dist/config/llm.config.d.ts +63 -0
  11. package/dist/config/llm.config.d.ts.map +1 -0
  12. package/dist/config/llm.config.js +158 -0
  13. package/dist/config/llm.config.js.map +1 -0
  14. package/dist/config/mcp.config.d.ts +175 -0
  15. package/dist/config/mcp.config.d.ts.map +1 -0
  16. package/dist/config/mcp.config.js +215 -0
  17. package/dist/config/mcp.config.js.map +1 -0
  18. package/dist/index.d.ts +3 -0
  19. package/dist/index.d.ts.map +1 -0
  20. package/dist/index.js +175 -0
  21. package/dist/index.js.map +1 -0
  22. package/dist/llm/llamaClient.d.ts +14 -0
  23. package/dist/llm/llamaClient.d.ts.map +1 -0
  24. package/dist/llm/llamaClient.js +136 -0
  25. package/dist/llm/llamaClient.js.map +1 -0
  26. package/dist/mcp/mcpClient.d.ts +132 -0
  27. package/dist/mcp/mcpClient.d.ts.map +1 -0
  28. package/dist/mcp/mcpClient.js +784 -0
  29. package/dist/mcp/mcpClient.js.map +1 -0
  30. package/dist/models/testSpec.d.ts +78 -0
  31. package/dist/models/testSpec.d.ts.map +1 -0
  32. package/dist/models/testSpec.js +3 -0
  33. package/dist/models/testSpec.js.map +1 -0
  34. package/dist/orchestrator/aiTestRunner.d.ts +18 -0
  35. package/dist/orchestrator/aiTestRunner.d.ts.map +1 -0
  36. package/dist/orchestrator/aiTestRunner.js +247 -0
  37. package/dist/orchestrator/aiTestRunner.js.map +1 -0
  38. package/dist/utils/logger.d.ts +4 -0
  39. package/dist/utils/logger.d.ts.map +1 -0
  40. package/dist/utils/logger.js +49 -0
  41. package/dist/utils/logger.js.map +1 -0
  42. package/dist/utils/promptBuilder.d.ts +62 -0
  43. package/dist/utils/promptBuilder.d.ts.map +1 -0
  44. package/dist/utils/promptBuilder.js +333 -0
  45. package/dist/utils/promptBuilder.js.map +1 -0
  46. package/knowledge/app-knowledge.txt +100 -0
  47. package/logs/combined.log +486 -0
  48. package/logs/error.log +50 -0
  49. package/package.json +62 -0
  50. package/reports/screenshots/screenshot_1764535110518.png +0 -0
  51. package/reports/test-report.json +106 -0
  52. package/scripts/check-mcp-server.sh +100 -0
  53. package/scripts/extract-pom-knowledge.js +222 -0
  54. package/scripts/pre-test-setup.js +262 -0
  55. package/scripts/start-mcp-server.sh +76 -0
  56. package/src/config/app.config.ts +175 -0
  57. package/src/config/llm.config.ts +220 -0
  58. package/src/config/mcp.config.ts +291 -0
  59. package/src/index.ts +161 -0
  60. package/src/llm/llamaClient.ts +159 -0
  61. package/src/mcp/mcpClient.ts +878 -0
  62. package/src/models/testSpec.ts +85 -0
  63. package/src/orchestrator/aiTestRunner.ts +286 -0
  64. package/src/utils/logger.ts +59 -0
  65. package/src/utils/promptBuilder.ts +384 -0
  66. package/tests/nlp-specs/login-flow.yaml +31 -0
  67. package/tsconfig.json +31 -0
@@ -0,0 +1,158 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.PromptTemplates = void 0;
7
+ exports.getPromptTemplate = getPromptTemplate;
8
+ exports.validateLLMConfig = validateLLMConfig;
9
+ exports.getProviderConfig = getProviderConfig;
10
+ const dotenv_1 = __importDefault(require("dotenv"));
11
+ dotenv_1.default.config();
12
+ const llmConfig = {
13
+ provider: process.env.LLM_PROVIDER || 'ollama',
14
+ connection: {
15
+ baseUrl: process.env.OLLAMA_BASE_URL || process.env.LLM_BASE_URL || 'http://localhost:11434',
16
+ timeout: parseInt(process.env.LLM_TIMEOUT || '60000'),
17
+ retryAttempts: parseInt(process.env.LLM_RETRY_ATTEMPTS || '3'),
18
+ retryDelay: parseInt(process.env.LLM_RETRY_DELAY || '2000'),
19
+ },
20
+ model: {
21
+ name: process.env.LLM_MODEL || 'llama3.2:3b',
22
+ temperature: parseFloat(process.env.LLM_TEMPERATURE || '0.1'),
23
+ maxTokens: parseInt(process.env.LLM_MAX_TOKENS || '2000'),
24
+ topP: parseFloat(process.env.LLM_TOP_P || '0.9'),
25
+ topK: parseInt(process.env.LLM_TOP_K || '40'),
26
+ frequencyPenalty: parseFloat(process.env.LLM_FREQUENCY_PENALTY || '0.0'),
27
+ presencePenalty: parseFloat(process.env.LLM_PRESENCE_PENALTY || '0.0'),
28
+ },
29
+ prompt: {
30
+ systemMessage: process.env.LLM_SYSTEM_MESSAGE ||
31
+ 'You are an expert mobile test automation agent specialized in Appium automation.',
32
+ includeAppContext: process.env.LLM_INCLUDE_APP_CONTEXT !== 'false',
33
+ includeUIContext: process.env.LLM_INCLUDE_UI_CONTEXT !== 'false',
34
+ maxUIElements: parseInt(process.env.LLM_MAX_UI_ELEMENTS || '30'),
35
+ maxContextTokens: parseInt(process.env.LLM_MAX_CONTEXT_TOKENS || '4000'),
36
+ includeReasoningInResponse: process.env.LLM_INCLUDE_REASONING !== 'false',
37
+ strictJsonMode: process.env.LLM_STRICT_JSON_MODE !== 'false',
38
+ },
39
+ performance: {
40
+ cachingEnabled: process.env.LLM_CACHING_ENABLED === 'true',
41
+ cacheTTL: parseInt(process.env.LLM_CACHE_TTL || '3600'),
42
+ batchRequests: process.env.LLM_BATCH_REQUESTS === 'true',
43
+ maxBatchSize: parseInt(process.env.LLM_MAX_BATCH_SIZE || '5'),
44
+ streamResponse: process.env.LLM_STREAM_RESPONSE === 'true',
45
+ },
46
+ fallback: {
47
+ enabled: process.env.LLM_FALLBACK_ENABLED === 'true',
48
+ fallbackModel: process.env.LLM_FALLBACK_MODEL,
49
+ maxFallbackAttempts: parseInt(process.env.LLM_FALLBACK_ATTEMPTS || '1'),
50
+ },
51
+ };
52
+ // Predefined prompt templates
53
+ exports.PromptTemplates = {
54
+ actionPlanning: `You are an expert mobile test automation agent. Your task is to generate precise Appium actions to accomplish a test step.
55
+
56
+ **Your Capabilities:**
57
+ - Analyze mobile app UI hierarchies (XML format)
58
+ - Identify the best element selectors (text, id, accessibility-id, xpath, class)
59
+ - Generate reliable action sequences (tap, type, scroll, swipe, wait, assert)
60
+ - Handle both Android and iOS platforms
61
+ - Adapt to different screen sizes and device configurations
62
+
63
+ **Priority for Element Selection:**
64
+ 1. Text content (exact or partial match)
65
+ 2. Accessibility ID or Content Description
66
+ 3. Resource ID (Android) or Name (iOS)
67
+ 4. Class name with additional attributes
68
+ 5. XPath (only when necessary)
69
+ 6. Coordinates (last resort)
70
+
71
+ **Action Types Available:**
72
+ - tap: Click/tap on an element
73
+ - type: Enter text into an input field
74
+ - scroll: Scroll in a direction (up, down, left, right)
75
+ - swipe: Swipe gesture in a direction
76
+ - wait: Wait for a duration or element
77
+ - assert: Verify element state (exists, visible, text, enabled)
78
+ - screenshot: Capture screen state`,
79
+ contextAnalysis: `Analyze the current UI context and identify key interactive elements that are relevant for accomplishing the given test step.
80
+
81
+ **Focus on:**
82
+ - Interactive elements (buttons, inputs, links)
83
+ - Navigation elements (tabs, back buttons)
84
+ - Text labels and headers for context
85
+ - Error messages or alerts
86
+ - Permission dialogs
87
+ - Loading indicators`,
88
+ errorRecovery: `The previous action attempt failed. Analyze the current UI state and suggest alternative approaches.
89
+
90
+ **Consider:**
91
+ - Is the target element visible and enabled?
92
+ - Are there any blocking dialogs or overlays?
93
+ - Is the app in an unexpected state?
94
+ - Are there alternative selectors for the same element?
95
+ - Should we wait for animations or transitions to complete?`,
96
+ assertionGeneration: `Generate appropriate assertions to verify the expected outcome of the test step.
97
+
98
+ **Common Assertions:**
99
+ - Element exists on screen
100
+ - Element is visible and enabled
101
+ - Text content matches expected value
102
+ - Specific screen or activity is displayed
103
+ - No error messages are present`,
104
+ };
105
+ // Helper function to get appropriate template
106
+ function getPromptTemplate(type) {
107
+ return exports.PromptTemplates[type];
108
+ }
109
+ // Validation
110
+ function validateLLMConfig() {
111
+ const errors = [];
112
+ // Check base URL
113
+ if (!llmConfig.connection.baseUrl) {
114
+ errors.push('LLM_BASE_URL or OLLAMA_BASE_URL is required');
115
+ }
116
+ // Validate model name
117
+ if (!llmConfig.model.name) {
118
+ errors.push('LLM_MODEL is required');
119
+ }
120
+ // Validate temperature range
121
+ if (llmConfig.model.temperature < 0 || llmConfig.model.temperature > 2) {
122
+ errors.push('LLM_TEMPERATURE must be between 0 and 2');
123
+ }
124
+ // Validate max tokens
125
+ if (llmConfig.model.maxTokens < 100 || llmConfig.model.maxTokens > 100000) {
126
+ errors.push('LLM_MAX_TOKENS must be between 100 and 100000');
127
+ }
128
+ // Validate timeout
129
+ if (llmConfig.connection.timeout < 5000) {
130
+ errors.push('LLM_TIMEOUT must be at least 5000ms');
131
+ }
132
+ if (errors.length > 0) {
133
+ throw new Error(`LLM configuration validation failed:\n${errors.join('\n')}`);
134
+ }
135
+ }
136
+ // Get configuration for specific provider
137
+ function getProviderConfig(provider) {
138
+ const configs = {
139
+ ollama: {
140
+ endpoint: '/api/generate',
141
+ healthEndpoint: '/api/tags',
142
+ format: 'ollama',
143
+ },
144
+ openai: {
145
+ endpoint: '/v1/chat/completions',
146
+ healthEndpoint: '/v1/models',
147
+ format: 'openai',
148
+ },
149
+ anthropic: {
150
+ endpoint: '/v1/messages',
151
+ healthEndpoint: '/v1/models',
152
+ format: 'anthropic',
153
+ },
154
+ };
155
+ return configs[provider] || configs.ollama;
156
+ }
157
+ exports.default = llmConfig;
158
+ //# sourceMappingURL=llm.config.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"llm.config.js","sourceRoot":"","sources":["../../src/config/llm.config.ts"],"names":[],"mappings":";;;;;;AA8JA,8CAEC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AAe;YACzB,cAAc,EAAE,WAAW;YAC3B,MAAM,EAAE,QAAQ;SACjB;QACD,MAAM,EAAE;YACN,QAAQ,EAAE,sBAAsB;YAChC,cAAc,EAAE,YAAY;YAC5B,MAAM,EAAE,QAAQ;SACjB;QACD,SAAS,EAAE;YACT,QAAQ,EAAE,cAAc;YACxB,cAAc,EAAE,YAAY;YAC5B,MAAM,EAAE,WAAW;SACpB;KACF,CAAC;IAEF,OAAO,OAAO,CAAC,QAAgC,CAAC,IAAI,OAAO,CAAC,MAAM,CAAC;AACrE,CAAC;AAED,kBAAe,SAAS,CAAC"}
@@ -0,0 +1,175 @@
1
+ export interface MCPConfig {
2
+ server: {
3
+ type: 'mcp-appium' | 'mobile-mcp' | 'custom';
4
+ host: string;
5
+ port: number;
6
+ protocol: 'http' | 'https' | 'stdio';
7
+ timeout: number;
8
+ };
9
+ appium: {
10
+ serverUrl: string;
11
+ sessionId?: string;
12
+ capabilities: {
13
+ platformName?: string;
14
+ platformVersion?: string;
15
+ deviceName?: string;
16
+ automationName?: string;
17
+ app?: string;
18
+ appPackage?: string;
19
+ appActivity?: string;
20
+ bundleId?: string;
21
+ };
22
+ };
23
+ tools: {
24
+ enabledTools: string[];
25
+ customTools?: Record<string, any>;
26
+ };
27
+ uiContext: {
28
+ capturePageSource: boolean;
29
+ parseXML: boolean;
30
+ includeInvisibleElements: boolean;
31
+ maxElementDepth: number;
32
+ elementFilters: {
33
+ excludeClasses: string[];
34
+ includeOnlyInteractive: boolean;
35
+ minTextLength: number;
36
+ };
37
+ };
38
+ actions: {
39
+ tapStrategy: 'center' | 'visible-center' | 'coordinates';
40
+ typeStrategy: 'native' | 'adb' | 'auto';
41
+ scrollStrategy: 'uiautomator' | 'gesture' | 'auto';
42
+ swipeStrategy: 'touch-action' | 'gesture' | 'auto';
43
+ waitStrategy: 'implicit' | 'explicit' | 'smart';
44
+ };
45
+ errorHandling: {
46
+ retryOnStaleElement: boolean;
47
+ retryOnNoSuchElement: boolean;
48
+ retryAttempts: number;
49
+ retryDelay: number;
50
+ captureScreenshotOnError: boolean;
51
+ capturePageSourceOnError: boolean;
52
+ };
53
+ performance: {
54
+ cacheUIContext: boolean;
55
+ cacheDuration: number;
56
+ parallelActions: boolean;
57
+ throttleActions: number;
58
+ };
59
+ }
60
+ declare const mcpConfig: MCPConfig;
61
+ export declare const MCPTools: {
62
+ find_element: {
63
+ name: string;
64
+ description: string;
65
+ parameters: {
66
+ strategy: string[];
67
+ value: string;
68
+ multiple: string;
69
+ };
70
+ };
71
+ tap: {
72
+ name: string;
73
+ description: string;
74
+ parameters: {
75
+ selector: string;
76
+ x: string;
77
+ y: string;
78
+ duration: string;
79
+ };
80
+ };
81
+ type: {
82
+ name: string;
83
+ description: string;
84
+ parameters: {
85
+ selector: string;
86
+ text: string;
87
+ clear: string;
88
+ };
89
+ };
90
+ scroll: {
91
+ name: string;
92
+ description: string;
93
+ parameters: {
94
+ direction: string[];
95
+ percentage: string;
96
+ element: string;
97
+ };
98
+ };
99
+ swipe: {
100
+ name: string;
101
+ description: string;
102
+ parameters: {
103
+ direction: string[];
104
+ startX: string;
105
+ startY: string;
106
+ endX: string;
107
+ endY: string;
108
+ duration: string;
109
+ };
110
+ };
111
+ get_page_source: {
112
+ name: string;
113
+ description: string;
114
+ parameters: {};
115
+ };
116
+ take_screenshot: {
117
+ name: string;
118
+ description: string;
119
+ parameters: {
120
+ path: string;
121
+ };
122
+ };
123
+ wait: {
124
+ name: string;
125
+ description: string;
126
+ parameters: {
127
+ selector: string;
128
+ condition: string[];
129
+ timeout: string;
130
+ duration: string;
131
+ };
132
+ };
133
+ get_current_activity: {
134
+ name: string;
135
+ description: string;
136
+ parameters: {};
137
+ };
138
+ press_key: {
139
+ name: string;
140
+ description: string;
141
+ parameters: {
142
+ key: string[];
143
+ };
144
+ };
145
+ };
146
+ export declare const SelectorPriority: string[];
147
+ export declare const PlatformConfig: {
148
+ android: {
149
+ automationName: string;
150
+ defaultTimeout: number;
151
+ keyboardStrategy: string;
152
+ preferredSelectors: string[];
153
+ };
154
+ ios: {
155
+ automationName: string;
156
+ defaultTimeout: number;
157
+ keyboardStrategy: string;
158
+ preferredSelectors: string[];
159
+ };
160
+ };
161
+ export declare function validateMCPConfig(): void;
162
+ export declare function getPlatformConfig(platform: 'android' | 'ios'): {
163
+ automationName: string;
164
+ defaultTimeout: number;
165
+ keyboardStrategy: string;
166
+ preferredSelectors: string[];
167
+ } | {
168
+ automationName: string;
169
+ defaultTimeout: number;
170
+ keyboardStrategy: string;
171
+ preferredSelectors: string[];
172
+ };
173
+ export declare function isToolEnabled(toolName: string): boolean;
174
+ export default mcpConfig;
175
+ //# sourceMappingURL=mcp.config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mcp.config.d.ts","sourceRoot":"","sources":["../../src/config/mcp.config.ts"],"names":[],"mappings":"AAIA,MAAM,WAAW,SAAS;IACxB,MAAM,EAAE;QACN,IAAI,EAAE,YAAY,GAAG,YAAY,GAAG,QAAQ,CAAC;QAC7C,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,EAAE,MAAM,CAAC;QACb,QAAQ,EAAE,MAAM,GAAG,OAAO,GAAG,OAAO,CAAC;QACrC,OAAO,EAAE,MAAM,CAAC;KACjB,CAAC;IAEF,MAAM,EAAE;QACN,SAAS,EAAE,MAAM,CAAC;QAClB,SAAS,CAAC,EAAE,MAAM,CAAC;QACnB,YAAY,EAAE;YACZ,YAAY,CAAC,EAAE,MAAM,CAAC;YACtB,eAAe,CAAC,EAAE,MAAM,CAAC;YACzB,UAAU,CAAC,EAAE,MAAM,CAAC;YACpB,cAAc,CAAC,EAAE,MAAM,CAAC;YACxB,GAAG,CAAC,EAAE,MAAM,CAAC;YACb,UAAU,CAAC,EAAE,MAAM,CAAC;YACpB,WAAW,CAAC,EAAE,MAAM,CAAC;YACrB,QAAQ,CAAC,EAAE,MAAM,CAAC;SACnB,CAAC;KACH,CAAC;IAEF,KAAK,EAAE;QACL,YAAY,EAAE,MAAM,E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C;AAGF,eAAO,MAAM,gBAAgB,UAO5B,CAAC;AAGF,eAAO,MAAM,cAAc;;;;;;;;;;;;;CAa1B,CAAC;AAGF,wBAAgB,iBAAiB,IAAI,IAAI,CA0BxC;AAGD,wBAAgB,iBAAiB,CAAC,QAAQ,EAAE,SAAS,GAAG,KAAK;;;;;;;;;;EAE5D;AAGD,wBAAgB,aAAa,CAAC,QAAQ,EAAE,MAAM,GAAG,OAAO,CAEvD;AAED,eAAe,SAAS,CAAC"}
@@ -0,0 +1,215 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.PlatformConfig = exports.SelectorPriority = exports.MCPTools = void 0;
7
+ exports.validateMCPConfig = validateMCPConfig;
8
+ exports.getPlatformConfig = getPlatformConfig;
9
+ exports.isToolEnabled = isToolEnabled;
10
+ const dotenv_1 = __importDefault(require("dotenv"));
11
+ dotenv_1.default.config();
12
+ const mcpConfig = {
13
+ server: {
14
+ type: process.env.MCP_SERVER_TYPE || 'mcp-appium',
15
+ host: process.env.MCP_SERVER_HOST || 'localhost',
16
+ port: parseInt(process.env.MCP_SERVER_PORT || '3000'),
17
+ protocol: process.env.MCP_PROTOCOL || 'http',
18
+ timeout: parseInt(process.env.MCP_TIMEOUT || '30000'),
19
+ },
20
+ appium: {
21
+ serverUrl: process.env.APPIUM_SERVER_URL || 'http://localhost:4723',
22
+ sessionId: process.env.APPIUM_SESSION_ID,
23
+ capabilities: {
24
+ platformName: process.env.PLATFORM_NAME,
25
+ platformVersion: process.env.PLATFORM_VERSION,
26
+ deviceName: process.env.DEVICE_NAME,
27
+ automationName: process.env.AUTOMATION_NAME,
28
+ app: process.env.APP_PATH,
29
+ appPackage: process.env.APP_PACKAGE,
30
+ appActivity: process.env.APP_ACTIVITY,
31
+ bundleId: process.env.BUNDLE_ID,
32
+ },
33
+ },
34
+ tools: {
35
+ enabledTools: (process.env.MCP_ENABLED_TOOLS ||
36
+ 'find_element,tap,type,scroll,swipe,get_page_source,take_screenshot').split(','),
37
+ customTools: {},
38
+ },
39
+ uiContext: {
40
+ capturePageSource: process.env.MCP_CAPTURE_PAGE_SOURCE !== 'false',
41
+ parseXML: process.env.MCP_PARSE_XML !== 'false',
42
+ includeInvisibleElements: process.env.MCP_INCLUDE_INVISIBLE === 'true',
43
+ maxElementDepth: parseInt(process.env.MCP_MAX_ELEMENT_DEPTH || '10'),
44
+ elementFilters: {
45
+ excludeClasses: (process.env.MCP_EXCLUDE_CLASSES ||
46
+ 'android.view.ViewGroup,android.widget.LinearLayout,UIView').split(','),
47
+ includeOnlyInteractive: process.env.MCP_ONLY_INTERACTIVE === 'true',
48
+ minTextLength: parseInt(process.env.MCP_MIN_TEXT_LENGTH || '1'),
49
+ },
50
+ },
51
+ actions: {
52
+ tapStrategy: process.env.MCP_TAP_STRATEGY || 'center',
53
+ typeStrategy: process.env.MCP_TYPE_STRATEGY || 'native',
54
+ scrollStrategy: process.env.MCP_SCROLL_STRATEGY || 'auto',
55
+ swipeStrategy: process.env.MCP_SWIPE_STRATEGY || 'auto',
56
+ waitStrategy: process.env.MCP_WAIT_STRATEGY || 'smart',
57
+ },
58
+ errorHandling: {
59
+ retryOnStaleElement: process.env.MCP_RETRY_STALE !== 'false',
60
+ retryOnNoSuchElement: process.env.MCP_RETRY_NO_ELEMENT === 'true',
61
+ retryAttempts: parseInt(process.env.MCP_ERROR_RETRY_ATTEMPTS || '2'),
62
+ retryDelay: parseInt(process.env.MCP_ERROR_RETRY_DELAY || '1000'),
63
+ captureScreenshotOnError: process.env.MCP_SCREENSHOT_ON_ERROR !== 'false',
64
+ capturePageSourceOnError: process.env.MCP_PAGE_SOURCE_ON_ERROR === 'true',
65
+ },
66
+ performance: {
67
+ cacheUIContext: process.env.MCP_CACHE_UI_CONTEXT === 'true',
68
+ cacheDuration: parseInt(process.env.MCP_CACHE_DURATION || '5000'),
69
+ parallelActions: process.env.MCP_PARALLEL_ACTIONS === 'true',
70
+ throttleActions: parseInt(process.env.MCP_THROTTLE_ACTIONS || '0'),
71
+ },
72
+ };
73
+ // MCP Tool definitions
74
+ exports.MCPTools = {
75
+ find_element: {
76
+ name: 'find_element',
77
+ description: 'Find an element on the screen using various selector strategies',
78
+ parameters: {
79
+ strategy: ['id', 'xpath', 'accessibility-id', 'text', 'class'],
80
+ value: 'string',
81
+ multiple: 'boolean',
82
+ },
83
+ },
84
+ tap: {
85
+ name: 'tap',
86
+ description: 'Tap/click on an element',
87
+ parameters: {
88
+ selector: 'object',
89
+ x: 'number (optional)',
90
+ y: 'number (optional)',
91
+ duration: 'number (optional)',
92
+ },
93
+ },
94
+ type: {
95
+ name: 'type',
96
+ description: 'Type text into an element',
97
+ parameters: {
98
+ selector: 'object',
99
+ text: 'string',
100
+ clear: 'boolean (optional)',
101
+ },
102
+ },
103
+ scroll: {
104
+ name: 'scroll',
105
+ description: 'Scroll the screen',
106
+ parameters: {
107
+ direction: ['up', 'down', 'left', 'right'],
108
+ percentage: 'number (optional)',
109
+ element: 'object (optional)',
110
+ },
111
+ },
112
+ swipe: {
113
+ name: 'swipe',
114
+ description: 'Perform swipe gesture',
115
+ parameters: {
116
+ direction: ['up', 'down', 'left', 'right'],
117
+ startX: 'number (optional)',
118
+ startY: 'number (optional)',
119
+ endX: 'number (optional)',
120
+ endY: 'number (optional)',
121
+ duration: 'number (optional)',
122
+ },
123
+ },
124
+ get_page_source: {
125
+ name: 'get_page_source',
126
+ description: 'Get the current page source (XML hierarchy)',
127
+ parameters: {},
128
+ },
129
+ take_screenshot: {
130
+ name: 'take_screenshot',
131
+ description: 'Capture a screenshot',
132
+ parameters: {
133
+ path: 'string (optional)',
134
+ },
135
+ },
136
+ wait: {
137
+ name: 'wait',
138
+ description: 'Wait for element or duration',
139
+ parameters: {
140
+ selector: 'object (optional)',
141
+ condition: ['exists', 'visible', 'enabled', 'clickable'],
142
+ timeout: 'number (optional)',
143
+ duration: 'number (optional)',
144
+ },
145
+ },
146
+ get_current_activity: {
147
+ name: 'get_current_activity',
148
+ description: 'Get current activity (Android) or bundle ID (iOS)',
149
+ parameters: {},
150
+ },
151
+ press_key: {
152
+ name: 'press_key',
153
+ description: 'Press device key',
154
+ parameters: {
155
+ key: ['home', 'back', 'enter', 'menu', 'volume_up', 'volume_down'],
156
+ },
157
+ },
158
+ };
159
+ // Selector strategies priority
160
+ exports.SelectorPriority = [
161
+ 'accessibility-id',
162
+ 'id',
163
+ 'text',
164
+ 'class',
165
+ 'xpath',
166
+ 'coordinates',
167
+ ];
168
+ // Platform-specific configurations
169
+ exports.PlatformConfig = {
170
+ android: {
171
+ automationName: 'UiAutomator2',
172
+ defaultTimeout: 30000,
173
+ keyboardStrategy: 'adb',
174
+ preferredSelectors: ['resource-id', 'content-desc', 'text'],
175
+ },
176
+ ios: {
177
+ automationName: 'XCUITest',
178
+ defaultTimeout: 30000,
179
+ keyboardStrategy: 'native',
180
+ preferredSelectors: ['accessibility-id', 'name', 'label'],
181
+ },
182
+ };
183
+ // Validation
184
+ function validateMCPConfig() {
185
+ const errors = [];
186
+ // Check Appium server URL
187
+ if (!mcpConfig.appium.serverUrl) {
188
+ errors.push('APPIUM_SERVER_URL is required');
189
+ }
190
+ // Validate server port
191
+ if (mcpConfig.server.port < 1 || mcpConfig.server.port > 65535) {
192
+ errors.push('MCP_SERVER_PORT must be between 1 and 65535');
193
+ }
194
+ // Validate timeout
195
+ if (mcpConfig.server.timeout < 1000) {
196
+ errors.push('MCP_TIMEOUT must be at least 1000ms');
197
+ }
198
+ // Validate element depth
199
+ if (mcpConfig.uiContext.maxElementDepth < 1 || mcpConfig.uiContext.maxElementDepth > 20) {
200
+ errors.push('MCP_MAX_ELEMENT_DEPTH must be between 1 and 20');
201
+ }
202
+ if (errors.length > 0) {
203
+ throw new Error(`MCP configuration validation failed:\n${errors.join('\n')}`);
204
+ }
205
+ }
206
+ // Helper to get platform-specific config
207
+ function getPlatformConfig(platform) {
208
+ return exports.PlatformConfig[platform];
209
+ }
210
+ // Helper to check if tool is enabled
211
+ function isToolEnabled(toolName) {
212
+ return mcpConfig.tools.enabledTools.includes(toolName);
213
+ }
214
+ exports.default = mcpConfig;
215
+ //# sourceMappingURL=mcp.config.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"mcp.config.js","sourceRoot":"","sources":["../../src/config/mcp.config.ts"],"names":[],"mappings":";;;;;;AA4PA,8CA0BC;AAGD,8CAEC;AAGD,sCAEC;AAhSD,oDAA4B;AAE5B,gBAAM,CAAC,MAAM,EAAE,CAAC;AAoEhB,MAAM,SAAS,GAAc;IAC3B,MAAM,EAAE;QACN,IAAI,EAAG,OAAO,CAAC,GAAG,CAAC,eAA0D,IAAI,YAAY;QAC7F,IAAI,EAAE,OAAO,CAAC,GAAG,CAAC,eAAe,IAAI,WAAW;QAChD,IAAI,EAAE,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,eAAe,IAAI,MAAM,CAAC;QACrD,QAAQ,EAAG,OAAO,CAAC,GAAG,CAAC,YAA2C,IAAI,MAAM;QAC5E,OAAO,EAAE,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,WAAW,IAAI,OAAO,CAAC;KACtD;IAED,MAAM,EAAE;QACN,SAAS,EAAE,OAAO,CAAC,GAAG,CAAC,iBAAiB,IAAI,uBAAuB;QACnE,SAAS,EAAE,OAAO,CAAC,GAAG,CAAC,iBAAiB;QACxC,YAAY,EAAE;YACZ,YAAY,EAAE,OAAO,CAAC,GAAG,CAAC,aAAa;YACvC,eAAe,EAAE,OAAO,CAAC,GAAG,CAAC,gBAAgB;YAC7C,UAAU,EAAE,OAAO,CAAC,GAAG,CAAC,WAAW;YACnC,cAAc,EAAE,OAAO,CAAC,GAAG,CAAC,eAAe;YAC3C,GAAG,EAAE,OAAO,CAAC,GAAG,CAAC,QAAQ;YACzB,UAAU,EAAE,OAAO,CAAC,GAAG,CAAC,WAAW;YACnC,WAAW,EAAE,OAAO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,yBAAyB;IACzB,IAAI,SAAS,CAAC,SAAS,CAAC,eAAe,GAAG,CAAC,IAAI,SAAS,CAAC,SAAS,CAAC,eAAe,GAAG,EAAE,EAAE,CAAC;QACxF,MAAM,CAAC,IAAI,CAAC,gDAAgD,CAAC,CAAC;IAChE,CAAC;IAED,IAAI,MAAM,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACtB,MAAM,IAAI,KAAK,CAAC,yCAAyC,MAAM,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC;IAChF,CAAC;AACH,CAAC;AAED,yCAAyC;AACzC,SAAgB,iBAAiB,CAAC,QAA2B;IAC3D,OAAO,sBAAc,CAAC,QAAQ,CAAC,CAAC;AAClC,CAAC;AAED,qCAAqC;AACrC,SAAgB,aAAa,CAAC,QAAgB;IAC5C,OAAO,SAAS,CAAC,KAAK,CAAC,YAAY,CAAC,QAAQ,CAAC,QAAQ,CAAC,CAAC;AACzD,CAAC;AAED,kBAAe,SAAS,CAAC"}
@@ -0,0 +1,3 @@
1
+ #!/usr/bin/env node
2
+ export {};
3
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":""}