This repository was archived by the owner on Jul 29, 2026. It is now read-only.
Repository navigation
Fix Gemini 3.5 Flash Computer Use: real scroll/keys + one-tap Phone CU mode - #1
Closed
jackspiece wants to merge 1 commit into
Closed
jackspiece wants to merge 1 commit into
jackspiece wants to merge 1 commit into
Conversation
…U mode The mobile & browser Computer Use handlers were coded for the LEGACY Gemini 2.5 action names. Gemini 3.5 Flash's mobile/browser environments emit a different, streamlined action set, so the actual actions the model sent fell through to the "unsupported action" branch and were silently no-op'd. That is why the agent literally could not scroll and keypresses did nothing. Engine (Kotlin): - VLMOperationService: add `scroll` (y,x,direction,magnitude_in_pixels), `press_key` (key), `list_apps`, and fix `drag_and_drop` to read start_x/start_y/end_x/end_y (with legacy x/destination_* fallback). Merge key_combination/hotkey (keys may be List or String) and add a normalizeHotKey() mapper. open_app now resolves app name -> package. - BrowserToolHandler: add `scroll` + left/right directions + press_key/ hotkey alongside the legacy names. - ScrollAction default duration 1.5s -> 0.3s (1.5s slow drag was read as a long-press drag, not a fling -> "barely scrolls"); VLMClient fallback too. drag_and_drop keeps an explicit 1.0s. - Rewrote the mobile system prompt (0-999 grid, verify screen changed, scroll to reveal content, prefer open_app/list_apps, tap field before type, be decisive, stop when done). - GEMINI_COMPUTER_USE_MAX_STEPS 30 -> 60 for longer tasks. UI (Flutter): - Scene model settings: one-tap "Phone Computer Use" card that binds the Operation + Agent scenes to gemini-3.5-flash on a Gemini provider profile (auto-enabling native Computer Use + high-reasoning), with an Active/Off status indicator and a guard dialog if no Gemini key is set.
Owner
Author
|
Closing this inactive experiment because I am narrowing my public contribution work to maintained upstream areas. The branch remains available. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What & why
The phone/browser agent felt "dumb" and couldn't scroll at all. Root cause: the Computer Use handlers were written for the legacy Gemini 2.5 action names, but the app runs Gemini 3.5 Flash, whose mobile/browser environments emit a different action set. The real actions (
scroll,press_key, etc.) fell through to the "unsupported action" branch and were silently no-op'd.Engine fixes (Kotlin)
scrollhandler added (paramsy, x, direction, magnitude_in_pixels) — this is the core scroll fix.press_key+ mergedkey_combination/hotkey(keys as List or String) +normalizeHotKey().list_appshandler (returns installed apps to the model).drag_and_dropnow readsstart_x/start_y/end_x/end_y(legacyx/destination_*fallback).open_appresolves app name to package viaresolvePackageName.ScrollActionduration 1.5s -> 0.3s (1.5s slow drag was read as long-press drag, not a fling -> "barely scrolls"); drag keeps 1.0s.GEMINI_COMPUTER_USE_MAX_STEPS30 -> 60.BrowserToolHandler.UI (Flutter)
gemini-3.5-flashon a Gemini provider profile (auto-enables native Computer Use + high reasoning), with an Active/Off indicator and a guard dialog if no Gemini key is set.Testing