Skip to content

feat: Sync from internal staging. - #94

Merged
chengfeitao-google merged 1 commit into
mainfrom
mobile-internal-sync-08182026
Aug 19, 2026
Merged

feat: Sync from internal staging.#94
chengfeitao-google merged 1 commit into
mainfrom
mobile-internal-sync-08182026

Conversation

@chengfeitao-google

Copy link
Copy Markdown
Collaborator

PiperOrigin-RevId: 966780314

Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:

  • Make sure to open an issue as a bug/issue before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea
  • Ensure the tests and linter pass
  • Code coverage does not decrease (if any source code was changed)
  • Appropriate docs were updated (if necessary)

[Sync] Update mobile web build configs, Python agent grounding, and travel mode handling

This update brings the following improvements and fixes:

1. Build Infrastructure

  • Self-contained iOS and Android web_build: Updated the export configuration to physically duplicate the shared mobile_core/web_build config files (index.html, tsconfig.json, vite.config.ts, core-shell.ts) directly into client/ios/web_build/ and client/android/web_build/.
  • Local core-shell imports: Updated main.ts in both iOS and Android web_build to import A2UICoreShell from ./core-shell instead of the shared parent.
  • Dropped client/mobile_core: Removed client/mobile_core from the exported repository to ensure npm install and npm run build work natively inside both client/ios/web_build and client/android/web_build without requiring a monorepo structure.

2. Python Agent & Schemas

  • Deterministic Place ID replacement (~40% latency reduction): Updated agent_with_grounding.py to replace synthetic PLACE_ID_FOR_* placeholders with grounded Place IDs using deterministic Python string substitution instead of a second LLM cleanup pass.
  • Mandatory travel_mode in DirectionsExtractorSchema: Removed default="driving" from DirectionsExtractorSchema to prevent lightweight models from silently defaulting to driving when travel_mode is omitted.
  • Expanded travel_mode synonym normalization: Enriched TRAVEL_MODE_MAP in extractor.py and merger.py to normalize a comprehensive set of synonyms (on foot, subway, auto, bus, train, metro, ferry, light rail, public transit, etc.).
  • Updated SKILL.md: Added few-shot examples for all four travel modes (driving, walking, transit, bicycling) in directions-template-response/SKILL.md.

3. Web Components

  • GoogleMap travelMode propagation: Fixed google_map.ts to propagate the travelMode property to gmp-route-3d, ensuring walking, transit, and bicycling routes render with the correct travel mode styling and timing.

4. Testing

  • Added unit tests for travelMode propagation and edge cases in google_map_test.ts.
  • Added unit tests for travel_mode schema validation, synonym normalization, and merger in test_extractor.py, test_merger.py, and test_agent_with_templates.py.

@chengfeitao-google
chengfeitao-google requested review from cbaueratwork and tirodkar and removed request for tirodkar August 18, 2026 22:39
Comment thread .github/workflows/web-ci.yml Fixed
Comment thread .github/workflows/web-ci.yml Fixed
Comment thread .github/workflows/web-ci.yml Fixed
@chengfeitao-google
chengfeitao-google force-pushed the mobile-internal-sync-08182026 branch from d6f5975 to f6dd90a Compare August 19, 2026 01:50
@chengfeitao-google
chengfeitao-google merged commit 986687e into main Aug 19, 2026
14 checks passed
@chengfeitao-google
chengfeitao-google deleted the mobile-internal-sync-08182026 branch August 19, 2026 01:51
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.

5 participants