mobile-mcp-ai 2.6.10__tar.gz → 2.7.0__tar.gz
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.
- {mobile_mcp_ai-2.6.10/mobile_mcp_ai.egg-info → mobile_mcp_ai-2.7.0}/PKG-INFO +36 -1
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/README.md +28 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/config.py +32 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/basic_tools_lite.py +852 -1843
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/mcp_tools/mcp_server.py +384 -466
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0/mobile_mcp_ai.egg-info}/PKG-INFO +36 -1
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/mobile_mcp_ai.egg-info/SOURCES.txt +10 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/mobile_mcp_ai.egg-info/requires.txt +8 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/setup.py +10 -1
- mobile_mcp_ai-2.7.0/tests/test_mind_cloud_my_space.py +80 -0
- mobile_mcp_ai-2.7.0/tests/test_mind_correct.py +73 -0
- mobile_mcp_ai-2.7.0/tests/test_mind_improved.py +83 -0
- mobile_mcp_ai-2.7.0/tests/test_mind_optimized.py +77 -0
- mobile_mcp_ai-2.7.0/tests/test_open_mind.py +37 -0
- mobile_mcp_ai-2.7.0/tests/test_priority_demo.py +81 -0
- mobile_mcp_ai-2.7.0/tests/test_simple.py +76 -0
- mobile_mcp_ai-2.7.0/tests/test_/344/270/276/346/212/245.py +136 -0
- mobile_mcp_ai-2.7.0/tests/test_/345/210/207/346/215/242/350/257/255/350/250/200/345/210/260English.py +158 -0
- mobile_mcp_ai-2.7.0/tests/test_/346/265/213/350/257/225.py +114 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/LICENSE +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/MANIFEST.in +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/__init__.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/__init__.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/device_manager.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/dynamic_config.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/ios_client_wda.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/ios_device_manager_wda.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/mobile_client.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/template_matcher.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/templates/close_buttons/auto_x_0112_151217.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/templates/close_buttons/auto_x_0112_152037.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/templates/close_buttons/auto_x_0112_152840.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/templates/close_buttons/auto_x_0112_153256.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/templates/close_buttons/auto_x_0112_154847.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/templates/close_buttons/gray_x_stock_ad.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/utils/__init__.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/utils/logger.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/utils/operation_history_manager.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/core/utils/smart_wait.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/docs/iOS_SETUP_GUIDE.md +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/mcp_tools/__init__.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/mobile_mcp_ai.egg-info/dependency_links.txt +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/mobile_mcp_ai.egg-info/entry_points.txt +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/mobile_mcp_ai.egg-info/not-zip-safe +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/mobile_mcp_ai.egg-info/top_level.txt +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/requirements.txt +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/setup.cfg +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/templates/close_buttons/auto_x_0112_151217.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/templates/close_buttons/auto_x_0112_152037.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/templates/close_buttons/auto_x_0112_152840.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/templates/close_buttons/auto_x_0112_153256.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/templates/close_buttons/auto_x_0112_154847.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/templates/close_buttons/gray_x_stock_ad.png +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/utils/__init__.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/utils/logger.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/utils/xml_formatter.py +0 -0
- {mobile_mcp_ai-2.6.10 → mobile_mcp_ai-2.7.0}/utils/xml_parser.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mobile-mcp-ai
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.7.0
|
|
4
4
|
Summary: 移动端自动化 MCP Server - 支持 Android/iOS,AI 功能可选(基础工具不需要 AI)
|
|
5
5
|
Home-page: https://github.com/test111ddff-hash/mobile-mcp-ai
|
|
6
6
|
Author: douzi
|
|
@@ -46,6 +46,10 @@ Requires-Dist: facebook-wda>=1.4.0; extra == "ios"
|
|
|
46
46
|
Provides-Extra: h5
|
|
47
47
|
Requires-Dist: Appium-Python-Client>=3.0.0; extra == "h5"
|
|
48
48
|
Requires-Dist: selenium>=4.0.0; extra == "h5"
|
|
49
|
+
Provides-Extra: windows
|
|
50
|
+
Requires-Dist: pyautogui>=0.9.0; extra == "windows"
|
|
51
|
+
Requires-Dist: pyperclip>=1.8.0; extra == "windows"
|
|
52
|
+
Requires-Dist: pygetwindow>=0.0.9; extra == "windows"
|
|
49
53
|
Provides-Extra: all
|
|
50
54
|
Requires-Dist: dashscope>=1.10.0; extra == "all"
|
|
51
55
|
Requires-Dist: openai>=1.0.0; extra == "all"
|
|
@@ -55,6 +59,9 @@ Requires-Dist: selenium>=4.0.0; extra == "all"
|
|
|
55
59
|
Requires-Dist: pytest>=8.0.0; extra == "all"
|
|
56
60
|
Requires-Dist: pytest-asyncio>=0.21.0; extra == "all"
|
|
57
61
|
Requires-Dist: allure-pytest>=2.13.0; extra == "all"
|
|
62
|
+
Requires-Dist: pyautogui>=0.9.0; extra == "all"
|
|
63
|
+
Requires-Dist: pyperclip>=1.8.0; extra == "all"
|
|
64
|
+
Requires-Dist: pygetwindow>=0.0.9; extra == "all"
|
|
58
65
|
Dynamic: author
|
|
59
66
|
Dynamic: author-email
|
|
60
67
|
Dynamic: classifier
|
|
@@ -336,6 +343,34 @@ tidevice list
|
|
|
336
343
|
|
|
337
344
|
保存后**重启 Cursor**。
|
|
338
345
|
|
|
346
|
+
### 批量执行用例(飞书集成)
|
|
347
|
+
|
|
348
|
+
如果你需要从飞书多维表格批量执行用例,`mobile_open_new_chat` 功能会自动打开新会话继续执行。
|
|
349
|
+
|
|
350
|
+
**macOS 用户:** 需要开启辅助功能权限
|
|
351
|
+
|
|
352
|
+
| 步骤 | 操作 |
|
|
353
|
+
|:---:|------|
|
|
354
|
+
| 1 | 打开「系统设置」 |
|
|
355
|
+
| 2 | 点击「隐私与安全性」 |
|
|
356
|
+
| 3 | 点击「辅助功能」 |
|
|
357
|
+
| 4 | 点击 + 号,添加 **Cursor.app** |
|
|
358
|
+
| 5 | 确保开关已打开 ✅ |
|
|
359
|
+
|
|
360
|
+
> ⚠️ 没有此权限,无法自动打开新会话继续执行
|
|
361
|
+
|
|
362
|
+
**Windows 用户:** 需要安装额外依赖
|
|
363
|
+
|
|
364
|
+
```bash
|
|
365
|
+
pip install mobile-mcp-ai[windows]
|
|
366
|
+
```
|
|
367
|
+
|
|
368
|
+
或手动安装:
|
|
369
|
+
|
|
370
|
+
```bash
|
|
371
|
+
pip install pyautogui pyperclip pygetwindow
|
|
372
|
+
```
|
|
373
|
+
|
|
339
374
|
---
|
|
340
375
|
|
|
341
376
|
## 🚀 使用示例
|
|
@@ -265,6 +265,34 @@ tidevice list
|
|
|
265
265
|
|
|
266
266
|
保存后**重启 Cursor**。
|
|
267
267
|
|
|
268
|
+
### 批量执行用例(飞书集成)
|
|
269
|
+
|
|
270
|
+
如果你需要从飞书多维表格批量执行用例,`mobile_open_new_chat` 功能会自动打开新会话继续执行。
|
|
271
|
+
|
|
272
|
+
**macOS 用户:** 需要开启辅助功能权限
|
|
273
|
+
|
|
274
|
+
| 步骤 | 操作 |
|
|
275
|
+
|:---:|------|
|
|
276
|
+
| 1 | 打开「系统设置」 |
|
|
277
|
+
| 2 | 点击「隐私与安全性」 |
|
|
278
|
+
| 3 | 点击「辅助功能」 |
|
|
279
|
+
| 4 | 点击 + 号,添加 **Cursor.app** |
|
|
280
|
+
| 5 | 确保开关已打开 ✅ |
|
|
281
|
+
|
|
282
|
+
> ⚠️ 没有此权限,无法自动打开新会话继续执行
|
|
283
|
+
|
|
284
|
+
**Windows 用户:** 需要安装额外依赖
|
|
285
|
+
|
|
286
|
+
```bash
|
|
287
|
+
pip install mobile-mcp-ai[windows]
|
|
288
|
+
```
|
|
289
|
+
|
|
290
|
+
或手动安装:
|
|
291
|
+
|
|
292
|
+
```bash
|
|
293
|
+
pip install pyautogui pyperclip pygetwindow
|
|
294
|
+
```
|
|
295
|
+
|
|
268
296
|
---
|
|
269
297
|
|
|
270
298
|
## 🚀 使用示例
|
|
@@ -102,6 +102,31 @@ class Config:
|
|
|
102
102
|
"false"
|
|
103
103
|
).lower() == "true"
|
|
104
104
|
|
|
105
|
+
# ==================== Token 优化(省钱模式)====================
|
|
106
|
+
# 启用 Token 优化(默认开启,只精简格式,不影响准确度)
|
|
107
|
+
TOKEN_OPTIMIZATION_ENABLED: bool = os.getenv(
|
|
108
|
+
"TOKEN_OPTIMIZATION_ENABLED",
|
|
109
|
+
"true"
|
|
110
|
+
).lower() == "true"
|
|
111
|
+
|
|
112
|
+
# list_elements 最大返回元素数量(默认 0 = 不限制,确保准确度)
|
|
113
|
+
MAX_ELEMENTS_RETURN: int = int(os.getenv("MAX_ELEMENTS_RETURN", "0"))
|
|
114
|
+
|
|
115
|
+
# take_screenshot_with_som 最大返回元素数量(默认 0 = 不限制)
|
|
116
|
+
MAX_SOM_ELEMENTS_RETURN: int = int(os.getenv("MAX_SOM_ELEMENTS_RETURN", "0"))
|
|
117
|
+
|
|
118
|
+
# 精简返回信息(只移除冗余提示文字,不影响数据)
|
|
119
|
+
COMPACT_RESPONSE: bool = os.getenv(
|
|
120
|
+
"COMPACT_RESPONSE",
|
|
121
|
+
"true"
|
|
122
|
+
).lower() == "true"
|
|
123
|
+
|
|
124
|
+
# 精简工具描述(减少每次请求的 token)
|
|
125
|
+
COMPACT_TOOL_DESCRIPTION: bool = os.getenv(
|
|
126
|
+
"COMPACT_TOOL_DESCRIPTION",
|
|
127
|
+
"true"
|
|
128
|
+
).lower() == "true"
|
|
129
|
+
|
|
105
130
|
@classmethod
|
|
106
131
|
def get_ai_platform(cls) -> Optional[str]:
|
|
107
132
|
"""获取优先使用的AI平台"""
|
|
@@ -137,6 +162,13 @@ class Config:
|
|
|
137
162
|
"device": {
|
|
138
163
|
"default_device_id": cls.DEFAULT_DEVICE_ID,
|
|
139
164
|
"lock_orientation": cls.LOCK_SCREEN_ORIENTATION,
|
|
165
|
+
},
|
|
166
|
+
"token_optimization": {
|
|
167
|
+
"enabled": cls.TOKEN_OPTIMIZATION_ENABLED,
|
|
168
|
+
"max_elements": cls.MAX_ELEMENTS_RETURN,
|
|
169
|
+
"max_som_elements": cls.MAX_SOM_ELEMENTS_RETURN,
|
|
170
|
+
"compact_response": cls.COMPACT_RESPONSE,
|
|
171
|
+
"compact_tool_desc": cls.COMPACT_TOOL_DESCRIPTION,
|
|
140
172
|
}
|
|
141
173
|
}
|
|
142
174
|
|