Skip to content

fix: resize ADB screenshots to model limit#399

Open
binichallein wants to merge 1 commit into
zai-org:mainfrom
binichallein:fix/screenshot-max-size-381
Open

fix: resize ADB screenshots to model limit#399
binichallein wants to merge 1 commit into
zai-org:mainfrom
binichallein:fix/screenshot-max-size-381

Conversation

@binichallein
Copy link
Copy Markdown

Summary

  • Fixes 输入图片大小限制 #381 by resizing ADB screenshots before base64 encoding when either dimension exceeds the 2048 model input limit.
  • Applies the same limit to fallback black screenshots so fallback images cannot trigger the same input-size error.
  • Adds regression tests for tall screenshots and fallback screenshot dimensions.

Test Plan

  • python -m pytest
  • pre-commit run --files phone_agent/adb/screenshot.py tests/test_screenshot_resize.py

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

输入图片大小限制

1 participant