vamp-mcp 0.1.9 → 0.2.3

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 (140) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +142 -107
  3. package/THIRD_PARTY_NOTICES.md +32 -27
  4. package/bin/vamp-mcp.mjs +37 -37
  5. package/notices/mcp-virtualbox-LICENSE +21 -21
  6. package/notices/mcp-virtualbox-PROVENANCE.json +37 -37
  7. package/package.json +51 -17
  8. package/runtime/backends/common/Test-Environment.ps1 +7 -6
  9. package/runtime/backends/common/guest-install.json +58 -0
  10. package/runtime/backends/common/guest_install.py +57 -0
  11. package/runtime/backends/common/host-support.cjs +16 -0
  12. package/runtime/backends/common/packer.cjs +16 -0
  13. package/runtime/backends/hyperv/scripts/Manage-Desktop.ps1 +40 -67
  14. package/runtime/backends/hyperv/scripts/Send-InstallerBoot.ps1 +25 -0
  15. package/runtime/backends/kvm/debian-preseed.cfg +35 -35
  16. package/runtime/backends/library/registry.py +77 -77
  17. package/runtime/backends/library/replay.py +154 -154
  18. package/runtime/backends/packer/answer_media.py +16 -0
  19. package/runtime/backends/packer/deploy-hyperv.ps1 +10 -0
  20. package/runtime/backends/packer/drivers.py +49 -0
  21. package/runtime/backends/packer/hyperv-network.ps1 +10 -0
  22. package/runtime/backends/packer/images.py +75 -0
  23. package/runtime/backends/packer/osinfo.py +113 -0
  24. package/runtime/backends/packer/policy.json +15 -0
  25. package/runtime/backends/packer/runner.py +224 -0
  26. package/runtime/backends/packer/templates.py +118 -0
  27. package/runtime/backends/packer/toolchain.py +80 -0
  28. package/runtime/backends/remote_ssh/server.mjs +321 -94
  29. package/runtime/backends/virtualbox/desktop.cjs +37 -0
  30. package/runtime/backends/virtualbox/display.py +101 -101
  31. package/runtime/backends/virtualbox/history.py +139 -139
  32. package/runtime/backends/virtualbox/mouse_click.py +15 -15
  33. package/runtime/backends/virtualbox/mouse_move.py +18 -18
  34. package/runtime/backends/virtualbox/profiles.json +46 -46
  35. package/runtime/backends/virtualbox/provision.py +238 -184
  36. package/runtime/backends/virtualbox/recording_listener.py +29 -29
  37. package/runtime/backends/virtualbox/recordings.py +39 -39
  38. package/runtime/backends/virtualbox/requirements.txt +7 -7
  39. package/runtime/backends/virtualbox/rpas/debian_first_boot/manifest.json +1 -1
  40. package/runtime/backends/virtualbox/rpas/debian_first_boot/run.robot +13 -13
  41. package/runtime/backends/virtualbox/rpas/debian_first_boot/workflow.py +75 -75
  42. package/runtime/backends/virtualbox/rpas/observe/manifest.json +7 -7
  43. package/runtime/backends/virtualbox/rpas/observe/run.robot +13 -13
  44. package/runtime/backends/virtualbox/rpas/observe/workflow.py +14 -14
  45. package/runtime/backends/virtualbox/server.mjs +440 -63
  46. package/runtime/backends/virtualbox/setup_windows_sdk.py +58 -58
  47. package/runtime/backends/virtualbox/shares.py +68 -68
  48. package/runtime/backends/virtualbox/snapshots.py +53 -53
  49. package/runtime/backends/virtualbox/transfers.py +89 -89
  50. package/runtime/backends/virtualbox/vnc.py +61 -61
  51. package/runtime/guest_keys.py +13 -13
  52. package/runtime/guest_setup/http/debian-preseed.cfg +39 -0
  53. package/runtime/guest_setup/http/postdeb.sh +94 -0
  54. package/runtime/guest_setup/http/postwin.ps1 +53 -0
  55. package/runtime/guest_setup/http/setup-all.ps1 +25 -0
  56. package/runtime/guest_setup/http/setup-win.cmd +7 -0
  57. package/runtime/guest_setup/http/setup.ps1 +44 -0
  58. package/runtime/guest_setup/http/setup.sh +50 -0
  59. package/runtime/guest_setup/kvm/setup-debian.sh +73 -0
  60. package/runtime/guest_setup/kvm/setup-windows.ps1 +52 -0
  61. package/runtime/guest_setup/recorder/README.txt +12 -8
  62. package/runtime/guest_setup/recorder/RECORDER-LICENSE +674 -674
  63. package/runtime/guest_setup/recorder/RECORDING-GUIDE.txt +31 -31
  64. package/runtime/guest_setup/recorder/apply-display.py +41 -41
  65. package/runtime/guest_setup/recorder/configure-debian-mirrors.py +62 -62
  66. package/runtime/guest_setup/recorder/configure-gdm.py +23 -0
  67. package/runtime/guest_setup/recorder/configure-session.ps1 +14 -0
  68. package/runtime/guest_setup/recorder/gnome-display.py +60 -60
  69. package/runtime/guest_setup/recorder/install-display-startup.py +66 -39
  70. package/runtime/guest_setup/recorder/install-hypervisor-drivers.ps1 +34 -0
  71. package/runtime/guest_setup/recorder/install-resolution-shortcut.ps1 +36 -0
  72. package/runtime/guest_setup/recorder/postwin.cmd +10 -10
  73. package/runtime/guest_setup/recorder/prepare-recording.py +30 -30
  74. package/runtime/guest_setup/recorder/recorder.zip +0 -0
  75. package/runtime/guest_setup/recorder/requirements-recorder.txt +2 -2
  76. package/runtime/guest_setup/recorder/session-policy.py +22 -0
  77. package/runtime/guest_setup/recorder/setup-user.py +53 -35
  78. package/runtime/guest_setup/recorder/setup-win.cmd +4 -11
  79. package/runtime/guest_setup/recorder/setup.ps1 +108 -30
  80. package/runtime/guest_setup/recorder/setup.sh +19 -1
  81. package/runtime/guest_setup/recorder/vamp-recorder.py +148 -148
  82. package/runtime/guest_setup/recorder/verify-recorder.py +4 -4
  83. package/runtime/guest_setup/recorder/windows-display.py +76 -76
  84. package/runtime/guest_setup/requirements.txt +2 -0
  85. package/runtime/guest_setup/setup-all.ps1 +35 -0
  86. package/runtime/guest_setup/setup-all.sh +22 -0
  87. package/runtime/guest_setup/vault/Install-VCRuntime.ps1 +26 -0
  88. package/runtime/guest_setup/vault/setup-guest-vault.ps1 +148 -0
  89. package/runtime/guest_setup/vault/setup-guest-vault.sh +75 -0
  90. package/runtime/recording_converter.py +230 -230
  91. package/runtime/requirements-mcp.txt +11 -11
  92. package/runtime/rpas/README.md +161 -161
  93. package/runtime/rpas/captcha_handoff/manifest.json +27 -27
  94. package/runtime/rpas/captcha_handoff/run.robot +16 -16
  95. package/runtime/rpas/captcha_handoff/workflow.py +11 -11
  96. package/runtime/rpas/common.resource +26 -26
  97. package/runtime/rpas/debian_update/manifest.json +27 -27
  98. package/runtime/rpas/debian_update/run.robot +17 -17
  99. package/runtime/rpas/debian_update/workflow.py +13 -13
  100. package/runtime/rpas/desktop_control/manifest.json +26 -26
  101. package/runtime/rpas/desktop_control/run.robot +27 -27
  102. package/runtime/rpas/desktop_control/workflow.py +51 -51
  103. package/runtime/rpas/firefox_launch/manifest.json +27 -27
  104. package/runtime/rpas/firefox_launch/run.robot +15 -15
  105. package/runtime/rpas/firefox_launch/workflow.py +25 -25
  106. package/runtime/rpas/firefox_naver/manifest.json +27 -27
  107. package/runtime/rpas/firefox_naver/run.robot +21 -21
  108. package/runtime/rpas/firefox_naver/workflow.py +28 -28
  109. package/runtime/rpas/kvm_validation/README.md +11 -11
  110. package/runtime/rpas/kvm_validation/manifest.json +28 -28
  111. package/runtime/rpas/kvm_validation/run.robot +30 -30
  112. package/runtime/rpas/kvm_validation/workflow.py +91 -91
  113. package/runtime/rpas/manifest.schema.json +105 -105
  114. package/runtime/rpas/naver_login/login.robot +25 -25
  115. package/runtime/rpas/naver_login/manifest.json +33 -33
  116. package/runtime/rpas/naver_login/run.robot +20 -20
  117. package/runtime/rpas/naver_login/workflow.py +32 -32
  118. package/runtime/rpas/windows_naver_recorded/README.md +24 -24
  119. package/runtime/rpas/windows_naver_recorded/conversion.json +25 -25
  120. package/runtime/rpas/windows_naver_recorded/manifest.json +28 -28
  121. package/runtime/rpas/windows_naver_recorded/run.robot +37 -37
  122. package/runtime/rpas/windows_naver_recorded/workflow.py +32 -32
  123. package/runtime/scripts/build_recorder_media.py +39 -39
  124. package/runtime/scripts/macos/setup-host.sh +126 -0
  125. package/runtime/scripts/remote_host_setup.sh +7 -4
  126. package/runtime/scripts/script_server.py +571 -0
  127. package/runtime/skills/vamp-rpa-ui-checks/SKILL.md +26 -0
  128. package/runtime/skills/vamp-rpa-ui-checks/agents/openai.yaml +4 -0
  129. package/runtime/skills/vamp-rpa-ui-checks/references/display.md +12 -0
  130. package/runtime/skills/vamp-rpa-ui-checks/references/user-guide.md +49 -0
  131. package/runtime/skills/vamp-ui-cleanup/SKILL.md +15 -0
  132. package/runtime/skills/vamp-ui-cleanup/agents/openai.yaml +4 -0
  133. package/runtime/skills/vamp-ui-validation/SKILL.md +27 -0
  134. package/runtime/skills/vamp-ui-validation/agents/openai.yaml +4 -0
  135. package/runtime/third_party/mcp-virtualbox/scripts/mouse_click.py +65 -65
  136. package/runtime/third_party/pyautogui-recorder/LICENSE +674 -674
  137. package/runtime/third_party/pyautogui-recorder/PROVENANCE.json +16 -16
  138. package/runtime/third_party/pyautogui-recorder/PyAutoGuiRecorder.py +169 -169
  139. package/runtime/third_party/pyautogui-recorder/README.md +53 -53
  140. package/runtime/scripts/build_debian_installer.py +0 -48
@@ -1,24 +1,24 @@
1
- # windows_naver_recorded
2
-
3
- Generated from `naver_login_rpa` without executing source code.
4
-
5
- - Guest: `windows11`, 1920×1080; source space: `guest`.
6
- - Review `conversion.json` and the private `recording.local.json` before replay.
7
- - `run.robot` controls the order; `workflow.py` and `recording_runtime.py` execute SPICE input.
8
- - Default run returns `needs_review` without connecting to the VM.
9
- - Explicit replay: `.venv/bin/python scripts/run_rpa.py windows_naver_recorded --var ALLOW_REPLAY:True --var SPICE_URI:<actual-guest-uri>`
10
- - This refined Naver package verifies login-screen arrival with YOLO+OCR; it never claims an account was signed in.
11
- - `recording.local.json` is excluded from Git because recorded keystrokes can contain credentials. Regenerate from a local source on a new checkout.
12
- - See [conversion guide](../../docs/RECORDING_CONVERSION.md) for refinement and credential replacement.
13
-
14
-
15
- ## 추가한 목적 검증
16
-
17
- 이 패키지의 최종 목표는 **네이버 로그인 화면 도달**입니다. `workflow.py`의 `Verify Naver Login Reached`는 YOLO+OCR로 ID·비밀번호·로그인 버튼, 위치 관계와 `nid.naver.com`을 함께 검사합니다. 실제 계정을 입력하거나 로그인 제출을 수행하는 패키지가 아닙니다. 기본 `LANGUAGES`는 `ko,en`입니다.
18
-
19
-
20
- ## 실제 검증 기록
21
-
22
- 2026-11-15 Windows KVM 게스트에서 원본의 80개 동작을 한 번 재생해 로그인 화면에 도달했습니다. 처음에는 제목 NAVER와 ID placeholder가 한 YOLO 영역으로 합쳐져 정확 문자열 검증이 실패했습니다. 개별 OCR reading으로 필드를 찾도록 수정한 뒤 클릭을 다시 재생하지 않고 현재 화면을 재검사해 ID·비밀번호·로그인 영역과 도메인을 확인했습니다. 실제 자격 증명은 입력/제출하지 않았습니다.
23
-
24
- 원래 실패 기록: `artifacts/windows-naver-recorded-live/`; 수정 후 읽기 전용 확인: `artifacts/windows-naver-recorded-verification/`. 이 증거는 로컬 artifacts이며 Git에 포함하지 않습니다.
1
+ # windows_naver_recorded
2
+
3
+ Generated from `naver_login_rpa` without executing source code.
4
+
5
+ - Guest: `windows11`, 1920×1080; source space: `guest`.
6
+ - Review `conversion.json` and the private `recording.local.json` before replay.
7
+ - `run.robot` controls the order; `workflow.py` and `recording_runtime.py` execute SPICE input.
8
+ - Default run returns `needs_review` without connecting to the VM.
9
+ - Explicit replay: `.venv/bin/python scripts/run_rpa.py windows_naver_recorded --var ALLOW_REPLAY:True --var SPICE_URI:<actual-guest-uri>`
10
+ - This refined Naver package verifies login-screen arrival with YOLO+OCR; it never claims an account was signed in.
11
+ - `recording.local.json` is excluded from Git because recorded keystrokes can contain credentials. Regenerate from a local source on a new checkout.
12
+ - See [conversion guide](../../docs/RECORDING_CONVERSION.md) for refinement and credential replacement.
13
+
14
+
15
+ ## 추가한 목적 검증
16
+
17
+ 이 패키지의 최종 목표는 **네이버 로그인 화면 도달**입니다. `workflow.py`의 `Verify Naver Login Reached`는 YOLO+OCR로 ID·비밀번호·로그인 버튼, 위치 관계와 `nid.naver.com`을 함께 검사합니다. 실제 계정을 입력하거나 로그인 제출을 수행하는 패키지가 아닙니다. 기본 `LANGUAGES`는 `ko,en`입니다.
18
+
19
+
20
+ ## 실제 검증 기록
21
+
22
+ 2026-11-15 Windows KVM 게스트에서 원본의 80개 동작을 한 번 재생해 로그인 화면에 도달했습니다. 처음에는 제목 NAVER와 ID placeholder가 한 YOLO 영역으로 합쳐져 정확 문자열 검증이 실패했습니다. 개별 OCR reading으로 필드를 찾도록 수정한 뒤 클릭을 다시 재생하지 않고 현재 화면을 재검사해 ID·비밀번호·로그인 영역과 도메인을 확인했습니다. 실제 자격 증명은 입력/제출하지 않았습니다.
23
+
24
+ 원래 실패 기록: `artifacts/windows-naver-recorded-live/`; 수정 후 읽기 전용 확인: `artifacts/windows-naver-recorded-verification/`. 이 증거는 로컬 artifacts이며 Git에 포함하지 않습니다.
@@ -1,25 +1,25 @@
1
- {
2
- "format_version": 1,
3
- "source_name": "naver_login_rpa",
4
- "source_sha256": "cd02dbe5b3aa7a30a772da3cbab2cd2edaf346872bd418daff685b736a328652",
5
- "guest_os": "windows11",
6
- "coordinate_space": "guest",
7
- "guest_resolution": [
8
- 1920,
9
- 1080
10
- ],
11
- "action_count": 80,
12
- "operations": {
13
- "key_down": 37,
14
- "key_up": 37,
15
- "click": 3,
16
- "wait": 3
17
- },
18
- "initial_win_r": true,
19
- "requires_review": true,
20
- "warnings": [
21
- "Mechanical conversion only: review target positions and replace waits with state checks.",
22
- "Review all recorded input for private credentials before replay or sharing.",
23
- "1 key(s) remain held at recording end; replay teardown will release them."
24
- ]
25
- }
1
+ {
2
+ "format_version": 1,
3
+ "source_name": "naver_login_rpa",
4
+ "source_sha256": "cd02dbe5b3aa7a30a772da3cbab2cd2edaf346872bd418daff685b736a328652",
5
+ "guest_os": "windows11",
6
+ "coordinate_space": "guest",
7
+ "guest_resolution": [
8
+ 1920,
9
+ 1080
10
+ ],
11
+ "action_count": 80,
12
+ "operations": {
13
+ "key_down": 37,
14
+ "key_up": 37,
15
+ "click": 3,
16
+ "wait": 3
17
+ },
18
+ "initial_win_r": true,
19
+ "requires_review": true,
20
+ "warnings": [
21
+ "Mechanical conversion only: review target positions and replace waits with state checks.",
22
+ "Review all recorded input for private credentials before replay or sharing.",
23
+ "1 key(s) remain held at recording end; replay teardown will release them."
24
+ ]
25
+ }
@@ -1,28 +1,28 @@
1
- {
2
- "format_version": 1,
3
- "id": "windows_naver_recorded",
4
- "name": "Windows 네이버 로그인 화면 접근 (수동 기록 변환)",
5
- "version": "0.1.0",
6
- "default_entrypoint": "run",
7
- "entrypoints": [
8
- {
9
- "name": "run",
10
- "file": "run.robot",
11
- "credentials": "environment_or_prompt"
12
- }
13
- ],
14
- "python_libraries": [
15
- "workflow.py"
16
- ],
17
- "dependencies": [
18
- "spice",
19
- "yolo",
20
- "paddleocr"
21
- ],
22
- "skill": "spice-recording-convert",
23
- "outputs": {
24
- "summary": "${OUTPUT DIR}/summary.json",
25
- "robot_log": "${OUTPUT DIR}/log.html",
26
- "robot_report": "${OUTPUT DIR}/report.html"
27
- }
28
- }
1
+ {
2
+ "format_version": 1,
3
+ "id": "windows_naver_recorded",
4
+ "name": "Windows 네이버 로그인 화면 접근 (수동 기록 변환)",
5
+ "version": "0.1.0",
6
+ "default_entrypoint": "run",
7
+ "entrypoints": [
8
+ {
9
+ "name": "run",
10
+ "file": "run.robot",
11
+ "credentials": "environment_or_prompt"
12
+ }
13
+ ],
14
+ "python_libraries": [
15
+ "workflow.py"
16
+ ],
17
+ "dependencies": [
18
+ "spice",
19
+ "yolo",
20
+ "paddleocr"
21
+ ],
22
+ "skill": "spice-recording-convert",
23
+ "outputs": {
24
+ "summary": "${OUTPUT DIR}/summary.json",
25
+ "robot_log": "${OUTPUT DIR}/log.html",
26
+ "robot_report": "${OUTPUT DIR}/report.html"
27
+ }
28
+ }
@@ -1,37 +1,37 @@
1
- *** Settings ***
2
- Resource ${CURDIR}/../common.resource
3
- Library ${CURDIR}/workflow.py WITH NAME Workflow
4
- Suite Setup Contract.Begin Result ${RPA_ID}
5
- Suite Teardown Stop RPA
6
- Task Teardown End Recorded Task
7
-
8
- *** Variables ***
9
- ${RPA_ID} windows_naver_recorded
10
- ${ALLOW_REPLAY} ${FALSE}
11
- ${EXPECTED_TEXT} ${EMPTY}
12
- ${LANGUAGES} ko,en
13
- ${DEVICE} auto
14
-
15
- *** Tasks ***
16
- Replay Reviewed Guest Recording
17
- ${ready}= Workflow.Load Recording ${ALLOW_REPLAY}
18
- IF not $ready
19
- ${review}= Workflow.Review Result
20
- Contract.Publish Result ${review}
21
- Skip Review conversion.json and recording.local.json; set ALLOW_REPLAY only after review.
22
- END
23
- Spice.Connect Spice ${SPICE_URI}
24
- Workflow.Check Guest Geometry
25
- ${count}= Workflow.Action Count
26
- FOR ${index} IN RANGE ${count}
27
- Workflow.Replay Event ${index}
28
- END
29
- ${result}= Workflow.Verify Naver Login Reached ${LANGUAGES} ${DEVICE}
30
- Contract.Publish Result ${result}
31
- Pause For User Verification ${result}
32
- Should Be Equal ${result}[status] succeeded
33
-
34
- *** Keywords ***
35
- End Recorded Task
36
- Run Keyword And Continue On Failure Workflow.Release Recorded Inputs
37
- Finish RPA Task
1
+ *** Settings ***
2
+ Resource ${CURDIR}/../common.resource
3
+ Library ${CURDIR}/workflow.py WITH NAME Workflow
4
+ Suite Setup Contract.Begin Result ${RPA_ID}
5
+ Suite Teardown Stop RPA
6
+ Task Teardown End Recorded Task
7
+
8
+ *** Variables ***
9
+ ${RPA_ID} windows_naver_recorded
10
+ ${ALLOW_REPLAY} ${FALSE}
11
+ ${EXPECTED_TEXT} ${EMPTY}
12
+ ${LANGUAGES} ko,en
13
+ ${DEVICE} auto
14
+
15
+ *** Tasks ***
16
+ Replay Reviewed Guest Recording
17
+ ${ready}= Workflow.Load Recording ${ALLOW_REPLAY}
18
+ IF not $ready
19
+ ${review}= Workflow.Review Result
20
+ Contract.Publish Result ${review}
21
+ Skip Review conversion.json and recording.local.json; set ALLOW_REPLAY only after review.
22
+ END
23
+ Spice.Connect Spice ${SPICE_URI}
24
+ Workflow.Check Guest Geometry
25
+ ${count}= Workflow.Action Count
26
+ FOR ${index} IN RANGE ${count}
27
+ Workflow.Replay Event ${index}
28
+ END
29
+ ${result}= Workflow.Verify Naver Login Reached ${LANGUAGES} ${DEVICE}
30
+ Contract.Publish Result ${result}
31
+ Pause For User Verification ${result}
32
+ Should Be Equal ${result}[status] succeeded
33
+
34
+ *** Keywords ***
35
+ End Recorded Task
36
+ Run Keyword And Continue On Failure Workflow.Release Recorded Inputs
37
+ Finish RPA Task
@@ -1,32 +1,32 @@
1
- """Generated adapter: keep detailed input and coordinates in Python/local data."""
2
- from pathlib import Path
3
- from robot.api.deco import keyword,library
4
- from recording_runtime import RecordedWorkflow
5
-
6
-
7
- @library(scope='SUITE',auto_keywords=False)
8
- class Workflow(RecordedWorkflow):
9
- def __init__(self):
10
- super().__init__(Path(__file__).resolve().parent)
11
-
12
- @keyword
13
- def verify_naver_login_reached(self,languages='ko,en',device='auto'):
14
- from robot.libraries.BuiltIn import BuiltIn
15
- from login_flow import detect_login_form
16
- from verification import detect_verification
17
- self.release_recorded_inputs()
18
- self.spice._pump(2)
19
- directory=Path(BuiltIn().get_variable_value('${OUTPUT DIR}'))/'destination'
20
- analysis=self.spice.analyze_guest_ui(str(directory/'ui.json'),languages,device)
21
- challenge=detect_verification([r for element in analysis['elements'] for r in element.get('readings',[])])
22
- if challenge['status']!='no_challenge_text':return challenge
23
- state=detect_login_form(analysis)
24
- roles=[role for role,element in state.get('form',{}).items() if element['kind']=='ui_region']
25
- # All semantic fields + browser origin are needed; YOLO must support at least one target region.
26
- verified=state['status']=='needs_credentials' and bool(roles)
27
- return {'status':'succeeded' if verified else 'verification_failed',
28
- 'goal':'naver_login_screen_reached','verification':'yolo_ocr',
29
- 'origin_verified':state.get('origin_verified',False),'form_verified':verified,
30
- 'yolo_roles':roles,'login_submitted':False,
31
- 'actions_replayed':self.completed,'details_path':str((directory/'ui.json').resolve()),
32
- **({} if verified else {'error_summary':state['status']})}
1
+ """Generated adapter: keep detailed input and coordinates in Python/local data."""
2
+ from pathlib import Path
3
+ from robot.api.deco import keyword,library
4
+ from recording_runtime import RecordedWorkflow
5
+
6
+
7
+ @library(scope='SUITE',auto_keywords=False)
8
+ class Workflow(RecordedWorkflow):
9
+ def __init__(self):
10
+ super().__init__(Path(__file__).resolve().parent)
11
+
12
+ @keyword
13
+ def verify_naver_login_reached(self,languages='ko,en',device='auto'):
14
+ from robot.libraries.BuiltIn import BuiltIn
15
+ from login_flow import detect_login_form
16
+ from verification import detect_verification
17
+ self.release_recorded_inputs()
18
+ self.spice._pump(2)
19
+ directory=Path(BuiltIn().get_variable_value('${OUTPUT DIR}'))/'destination'
20
+ analysis=self.spice.analyze_guest_ui(str(directory/'ui.json'),languages,device)
21
+ challenge=detect_verification([r for element in analysis['elements'] for r in element.get('readings',[])])
22
+ if challenge['status']!='no_challenge_text':return challenge
23
+ state=detect_login_form(analysis)
24
+ roles=[role for role,element in state.get('form',{}).items() if element['kind']=='ui_region']
25
+ # All semantic fields + browser origin are needed; YOLO must support at least one target region.
26
+ verified=state['status']=='needs_credentials' and bool(roles)
27
+ return {'status':'succeeded' if verified else 'verification_failed',
28
+ 'goal':'naver_login_screen_reached','verification':'yolo_ocr',
29
+ 'origin_verified':state.get('origin_verified',False),'form_verified':verified,
30
+ 'yolo_roles':roles,'login_submitted':False,
31
+ 'actions_replayed':self.completed,'details_path':str((directory/'ui.json').resolve()),
32
+ **({} if verified else {'error_summary':state['status']})}
@@ -1,39 +1,39 @@
1
- #!/usr/bin/env python3
2
- """Build offline guest installer media; never executes the guest recorder."""
3
- from pathlib import Path
4
- import argparse
5
- import io
6
- import json
7
- import zipfile
8
-
9
- ROOT = Path(__file__).resolve().parents[1]
10
-
11
- def build(output=None):
12
- import pycdlib
13
- destination = Path(output or ROOT/'artifacts/recorder-setup.iso').resolve()
14
- destination.parent.mkdir(parents=True,exist_ok=True)
15
- payload = io.BytesIO()
16
- with zipfile.ZipFile(payload,'w',zipfile.ZIP_DEFLATED) as archive:
17
- for path in sorted((ROOT/'third_party/pyautogui-recorder').rglob('*')):
18
- if path.is_file():
19
- archive.write(path,str(path.relative_to(ROOT/'third_party/pyautogui-recorder')))
20
- files = {'recorder.zip':payload.getvalue()}
21
- files.update({p.name:p.read_bytes() for p in (ROOT/'guest_setup/recorder').iterdir() if p.is_file()})
22
- iso = pycdlib.PyCdlib()
23
- iso.new(interchange_level=3,joliet=3,vol_ident='RPA_RECORDER')
24
- buffers=[]
25
- try:
26
- for index,(name,content) in enumerate(sorted(files.items())):
27
- stream=io.BytesIO(content);buffers.append(stream)
28
- iso.add_fp(stream,len(content),iso_path=f'/FILE{index:03d}.DAT;1',joliet_path='/'+name)
29
- iso.write(str(destination))
30
- finally: iso.close()
31
- return {'status':'media_built','iso':str(destination),'guest_setup_completed':False,
32
- 'guest_installers':{'windows11':'setup-win.cmd','debian':'setup.sh'},
33
- 'recorder_license':'GPL-3.0','recording_started':False}
34
-
35
- if __name__=='__main__':
36
- parser=argparse.ArgumentParser(description=__doc__)
37
- parser.add_argument('--output')
38
- args=parser.parse_args()
39
- print(json.dumps(build(args.output)))
1
+ #!/usr/bin/env python3
2
+ """Build offline guest installer media; never executes the guest recorder."""
3
+ from pathlib import Path
4
+ import argparse
5
+ import io
6
+ import json
7
+ import zipfile
8
+
9
+ ROOT = Path(__file__).resolve().parents[1]
10
+
11
+ def build(output=None):
12
+ import pycdlib
13
+ destination = Path(output or ROOT/'artifacts/recorder-setup.iso').resolve()
14
+ destination.parent.mkdir(parents=True,exist_ok=True)
15
+ payload = io.BytesIO()
16
+ with zipfile.ZipFile(payload,'w',zipfile.ZIP_DEFLATED) as archive:
17
+ for path in sorted((ROOT/'third_party/pyautogui-recorder').rglob('*')):
18
+ if path.is_file():
19
+ archive.write(path,str(path.relative_to(ROOT/'third_party/pyautogui-recorder')))
20
+ files = {'recorder.zip':payload.getvalue()}
21
+ files.update({p.name:p.read_bytes() for p in (ROOT/'guest_setup/recorder').iterdir() if p.is_file()})
22
+ iso = pycdlib.PyCdlib()
23
+ iso.new(interchange_level=3,joliet=3,vol_ident='RPA_RECORDER')
24
+ buffers=[]
25
+ try:
26
+ for index,(name,content) in enumerate(sorted(files.items())):
27
+ stream=io.BytesIO(content);buffers.append(stream)
28
+ iso.add_fp(stream,len(content),iso_path=f'/FILE{index:03d}.DAT;1',joliet_path='/'+name)
29
+ iso.write(str(destination))
30
+ finally: iso.close()
31
+ return {'status':'media_built','iso':str(destination),'guest_setup_completed':False,
32
+ 'guest_installers':{'windows11':'setup-win.cmd','debian':'setup.sh'},
33
+ 'recorder_license':'GPL-3.0','recording_started':False}
34
+
35
+ if __name__=='__main__':
36
+ parser=argparse.ArgumentParser(description=__doc__)
37
+ parser.add_argument('--output')
38
+ args=parser.parse_args()
39
+ print(json.dumps(build(args.output)))
@@ -0,0 +1,126 @@
1
+ #!/usr/bin/env bash
2
+ # VAMP host setup for macOS.
3
+ #
4
+ # Prepares this Mac to run VAMP's VirtualBox host tools: finds a Python 3.11+
5
+ # interpreter (3.15 and newer are accepted), creates .venv-virtualbox, installs
6
+ # the host requirements, and builds the bundled VirtualBox MCP adapter.
7
+ #
8
+ # Safe to run repeatedly. It never removes VMs, disks or settings, and it does
9
+ # not install system packages or change your shell profile.
10
+ # Usage:
11
+ # scripts/macos/setup-host.sh [--python PATH] [--skip-npm]
12
+ #
13
+ # Environment:
14
+ # VAMP_PYTHON interpreter to use instead of auto-detection
15
+ set -euo pipefail
16
+
17
+ skip_npm=0
18
+ python_hint="${VAMP_PYTHON:-}"
19
+
20
+ while [ $# -gt 0 ]; do
21
+ case "$1" in
22
+ --python) [ $# -ge 2 ] || { echo 'vamp: --python needs a path' >&2; exit 2; }; python_hint="$2"; shift 2 ;;
23
+ --skip-npm) skip_npm=1; shift ;;
24
+ -h|--help) sed -n '2,14p' "$0" | sed 's/^# \{0,1\}//'; exit 0 ;;
25
+ *) echo "vamp: unknown option: $1" >&2; exit 2 ;;
26
+ esac
27
+ done
28
+
29
+ say() { printf 'vamp: %s\n' "$1"; }
30
+ die() { printf 'vamp: %s\n' "$1" >&2; exit 1; }
31
+
32
+ if [ "$(uname -s)" != Darwin ]; then
33
+ die "this script prepares a macOS host; on Linux use scripts/remote_host_setup.sh and on Windows use scripts/windows/setup-host.ps1"
34
+ fi
35
+
36
+ script_dir="$(cd -- "$(dirname -- "$0")" && pwd)"
37
+ root="$(cd -- "$script_dir/../.." && pwd)"
38
+ cd "$root"
39
+ [ -f backends/virtualbox/requirements.txt ] || die "run this from the VAMP checkout; backends/virtualbox/requirements.txt is missing"
40
+
41
+ # --- Python 3.11 or newer. The interpreter compares its own version tuple, so
42
+ # --- any later release (3.15, 3.16) is accepted without a version list here.
43
+ python_ok() {
44
+ [ -n "${1:-}" ] || return 1
45
+ case "$1" in
46
+ */*) [ -x "$1" ] || return 1 ;;
47
+ *) command -v "$1" >/dev/null 2>&1 || return 1 ;;
48
+ esac
49
+ "$1" -c 'import sys; raise SystemExit(0 if sys.version_info >= (3, 11) else 1)' >/dev/null 2>&1
50
+ }
51
+
52
+ python_bin=""
53
+ if [ -n "$python_hint" ]; then
54
+ python_ok "$python_hint" || die "'$python_hint' is not Python 3.11+; install Python 3.11 or newer (3.15 and newer work too) or repair that path"
55
+ python_bin="$python_hint"
56
+ else
57
+ for candidate in \
58
+ /opt/homebrew/bin/python3 \
59
+ /usr/local/bin/python3 \
60
+ /Library/Frameworks/Python.framework/Versions/3.16/bin/python3 \
61
+ /Library/Frameworks/Python.framework/Versions/3.15/bin/python3 \
62
+ /Library/Frameworks/Python.framework/Versions/3.14/bin/python3 \
63
+ /Library/Frameworks/Python.framework/Versions/3.13/bin/python3 \
64
+ /Library/Frameworks/Python.framework/Versions/3.12/bin/python3 \
65
+ /Library/Frameworks/Python.framework/Versions/3.11/bin/python3 \
66
+ python3.15 python3.14 python3.13 python3.12 python3.11 python3; do
67
+ if python_ok "$candidate"; then python_bin="$candidate"; break; fi
68
+ done
69
+ fi
70
+ [ -n "$python_bin" ] || die "Python 3.11 or newer is required (3.11 through 3.15+ are supported). Install it from https://www.python.org/downloads/ or 'brew install python@3.15', then run this script again."
71
+ say "using $("$python_bin" -c 'import sys; print("Python %d.%d.%d" % sys.version_info[:3])') ($python_bin)"
72
+
73
+ # --- Node.js 22+ runs the VirtualBox MCP server from the extension runtime.
74
+ if ! command -v node >/dev/null 2>&1; then
75
+ die "Node.js 22+ is required. Install it from https://nodejs.org/ or 'brew install node@22', then run this script again."
76
+ fi
77
+ node_major="$(node -p 'process.versions.node.split(".")[0]' 2>/dev/null || echo 0)"
78
+ [ "$node_major" -ge 22 ] 2>/dev/null || die "Node.js 22+ is required; found $(node --version 2>/dev/null)."
79
+ say "using Node.js $(node --version)"
80
+
81
+ # --- VirtualBox is a separate download on macOS and needs its kext approval.
82
+ vbox=""
83
+ if [ -d /Applications/VirtualBox.app ] || command -v VBoxManage >/dev/null 2>&1; then
84
+ vbox="$(command -v VBoxManage || echo /Applications/VirtualBox.app/Contents/MacOS/VBoxManage)"
85
+ say "VirtualBox found: $("$vbox" --version 2>/dev/null || echo "$vbox")"
86
+ else
87
+ say "VirtualBox was not found. Install it from https://www.virtualbox.org/wiki/Downloads and approve its kernel extension in System Settings > Privacy & Security. Remote and KVM over SSH desktops do not need it."
88
+ fi
89
+
90
+ # --- Isolated Python environment for the host tools.
91
+ if [ ! -x .venv-virtualbox/bin/python ]; then
92
+ say "creating .venv-virtualbox"
93
+ "$python_bin" -m venv .venv-virtualbox
94
+ else
95
+ say "reusing .venv-virtualbox"
96
+ fi
97
+ say "installing backends/virtualbox/requirements.txt"
98
+ .venv-virtualbox/bin/python -m pip install --disable-pip-version-check --upgrade pip >/dev/null
99
+ .venv-virtualbox/bin/python -m pip install --disable-pip-version-check -r backends/virtualbox/requirements.txt
100
+
101
+ if [ "$skip_npm" = "0" ]; then
102
+ if command -v npm >/dev/null 2>&1; then
103
+ say "building the VirtualBox MCP adapter"
104
+ ( cd third_party/mcp-virtualbox && npm ci --ignore-scripts && npm run build )
105
+ else
106
+ say "npm is missing; skipped the adapter build. The VS Code extension ships it already."
107
+ fi
108
+ fi
109
+
110
+ cat <<EOF
111
+
112
+ vamp: host environment ready.
113
+ python $root/.venv-virtualbox/bin/python
114
+ VBoxManage ${vbox:-not installed}
115
+
116
+ Next, for a terminal session:
117
+ export RPA_HOST_PYTHON="$root/.venv-virtualbox/bin/python"
118
+ export PYTHON_PATH="$root/.venv-virtualbox/bin/python"
119
+ export VBOXMANAGE_PATH="${vbox:-/Applications/VirtualBox.app/Contents/MacOS/VBoxManage}"
120
+ "$root/.venv-virtualbox/bin/python" -c "import mcp, robot, asyncvnc"
121
+ "$root/.venv-virtualbox/bin/python" scripts/windows/host-smoke.py # needs VirtualBox
122
+
123
+ The VirtualBox mouse SDK is separate: on Apple silicon, mouse replay needs a
124
+ Python build and vboxapi matching your VirtualBox version. Set VAMP: Mouse
125
+ Python Executable when the SDK lives in another interpreter.
126
+ EOF
@@ -71,10 +71,13 @@ fi
71
71
  python_bin="${VAMP_REMOTE_PYTHON:-python3}"
72
72
  if have "$python_bin"; then
73
73
  python_version="$("$python_bin" -c 'import sys;print("%d.%d.%d"%sys.version_info[:3])' 2>/dev/null)"
74
- case "$python_version" in
75
- 3.11.*|3.12.*|3.13.*|3.14.*|4.*) add_step python "Python 3.11+" ok "$python_bin -V" "$python_version" ;;
76
- *) add_step python "Python 3.11+" needs_manual "$python_bin -V" "found $python_version; install 3.11 or newer" ;;
77
- esac
74
+ # Compare the interpreter's own version tuple so any future release (3.15, 3.16,
75
+ # 4.x) passes without a hardcoded version list to maintain.
76
+ if "$python_bin" -c 'import sys; sys.exit(0 if sys.version_info >= (3, 11) else 1)' >/dev/null 2>&1; then
77
+ add_step python "Python 3.11+ (supports 3.15+)" ok "$python_bin -V" "${python_version:-unknown}"
78
+ else
79
+ add_step python "Python 3.11+" needs_manual "$python_bin -V" "found ${python_version:-unknown}; install 3.11 or newer"
80
+ fi
78
81
  if [ "$dry_run" = "0" ] && [ ! -x "$workdir/venv/bin/python" ]; then
79
82
  say "creating Python virtual environment"
80
83
  if "$python_bin" -m venv "$workdir/venv" >/dev/null 2>&1; then