Repository navigation
feat(AgenticNavigation): add Agentic Navigation SDK (v8.2.0) voice copilot (:app + :server) with Google Maps grounding attribution - #39
Draft
LoyalAbbas wants to merge 1 commit into
Draft
LoyalAbbas wants to merge 1 commit into
LoyalAbbas wants to merge 1 commit into
Conversation
LoyalAbbas
force-pushed
the
feat/agentic_nav_Sdk
branch
from
November 30, 2026 12:14
dc8bafb to
bfd1a4f
Compare
…pilot (:app + :server) with Google Maps grounding attribution
LoyalAbbas
force-pushed
the
feat/agentic_nav_Sdk
branch
from
December 4, 2026 04:27
bfd1a4f to
a76b5e8
Compare
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Adds the Agentic Navigation SDK (v8.2.0) to
navigation-sampleas a two-module Gradle project (:app+:server), demonstrating live turn-by-turn navigation voice assistance with NavSDKToolExecutor, Gemini function calling, and compliant Grounding with Google Maps attribution.:appholds zero LLM API keys—all Gemini API calls, partner backend tools, and Google Maps grounding are owned by:server.Key Changes
Build & Configuration
navSdk) from8.0.0to8.2.0ingradle/libs.versions.toml.:serverKotlin/JVM (Java 17) subproject (settings.gradle.kts,server/build.gradle.kts,server/Dockerfile) using Ktor Netty (3.4.0),com.google.genai:google-genai(2.6.0), andkotlinx-serialization-json(1.9.0)..DS_Storeto.gitignoreand keptsecrets.propertiesgitignored for localMAPS_API_KEY/AGENT_SERVER_URLoverrides.:server— Ktor Relay, Gemini Orchestration & Google Maps GroundingApplication.kt,ProtocolModels.kt,ServerConfig.kt):GET /health,POST /api/chat/start, andPOST /api/chat/tool-resultswith security headers and optional constant-timeX-Sample-Authverification.gemini-3.5-flash-lite,GEMINI_API_VERSION=v1, andENABLE_MAPS_GROUNDING=true(all configurable via env vars).GroundingSource(title, uri, placeId)and returnsgroundingSources: List<GroundingSource> = emptyList()in everyDONEresponse.ModelGateway.kt,PromptBuilder.kt):FunctionDeclaration.parametersJsonSchema.ToolConfig.includeServerSideToolInvocations = truewhen combining Google Maps grounding with custom function calling.groundingChunks -> maps()(title,uri,placeId) andmaps.placeAnswerSources().reviewSnippets()(title,googleMapsUri).AgentOrchestrator.kt,SessionStore.kt,PartnerTools.kt):Contentacross rounds (preserving Gemini 3thoughtSignatureand server-side tool invocations).groundingSourcesbyuriacross all rounds of a turn.clientToolsis empty, holds side-effect server tools (completeTrip,messagePassenger) until phone tool results succeed, guarantees 1:1FunctionResponseordering, caches per-round responses for idempotent retries, and evicts in-memory sessions after a 2-minute TTL.:app— Push-to-Talk Voice Copilot & Grounding Attribution UIAgenticNavActivity.kt,MainActivity.kt,NavToolBridge.kt,RemoteAgentClient.kt):AgenticNavActivitywith a simulated Mountain View demo route, push-to-talk voice controls, debug-only cleartext loopback config (app/src/debug/res/xml/network_security_config.xml), andDUMP-gated debug query broadcast receiver.ToolExecutordescriptors/execution on the main thread and relays turns viaRemoteAgentClient(with kill-switch fast-fail and timeout retry).VoiceAssistantController.kt,VoiceAssistantButton.kt):SpeechRecognizer,TextToSpeech,AudioManagerfocus ducking, barge-in, and yielding to turn-by-turn voice guidance viaNavigator.AudioGuidancePlaybackListener.AgentTranscriptStore.kt,activity_agentic_nav.xml,item_grounding_source.xml,item_transcript_turn.xml):SharedPreferences, or saved instance state; cleared on new route start or activity destroy).Sourceslist below grounded replies, and a 1-tap expandableSession Transcriptoverlay."AI-generated answers may include information from Google Maps. View sources below.") whenever Maps-grounded content is displayed."Google Maps"string (translatable="false", single-line/no-wrap, Roboto/sans-serif, normal weight 400,12sp,#FFFFFFon dark#2D2E31surface with >4.5:1 contrast), the source title, and HTTP/HTTPS-validatedIntent.ACTION_VIEWlink handling.Documentation
README.mdwith:server+:appsetup (emulator and USB),ENABLE_MAPS_GROUNDINGtoggle, Google Maps attribution behavior, and Cloud Run deployment instructions.AGENTIC_ARCHITECTURE.mddocumenting the relay protocol, sequence diagram, and safety invariants.Testing
All unit tests run offline with zero API keys:
./gradlew :server:test— 15 passed, 0 failed (PromptAndSchemaTest,AgentOrchestratorTest,ServerRoutesTest)../gradlew :app:testDebugUnitTest— 12 passed, 0 failed (RemoteAgentClientTest,VoiceAssistantControllerTest,AgentTranscriptStoreTest)../gradlew :app:assembleDebug— build succeeded.