mirror of
https://github.com/NousResearch/atropos.git
synced 2026-04-22 16:48:57 +00:00
1.9 KiB
1.9 KiB
Google Maps Integration for Stone AIOS
This module enables Stone AIOS to provide location information, directions, and other map-related services using Google Maps.
Features
- Location Search: Find detailed information about places
- Directions: Get directions between locations with different transport modes
- Distance Calculation: Calculate distances and travel times
- Place Details: Get information about businesses, landmarks, etc.
Requirements
- Google Cloud account with Maps API enabled
- Google Maps API key with the following APIs enabled:
- Maps JavaScript API
- Places API
- Directions API
- Distance Matrix API
- Geocoding API
Configuration
- Set up a Google Cloud project and enable the necessary Google Maps APIs
- Create an API key and restrict it to the Google Maps APIs
- Configure your
.envfile with:
GOOGLE_MAPS_API_KEY="your_google_maps_api_key"
Integration Details
The Google Maps integration uses an MCP server implemented in JavaScript that runs as a subprocess when needed. This ensures the maps service only consumes resources when actively being used.
Supported Commands
- "Where is the Eiffel Tower?" - Get location information
- "How do I get from New York to Boston?" - Get directions
- "How far is it from Los Angeles to San Francisco?" - Calculate distances
- "What restaurants are near me?" - Find nearby places (requires user location)
Implementation Notes
The integration is implemented in agents/stone_agent.py within the delegate_to_go_agent function, which handles:
- Verifying the presence of a valid Google Maps API key
- Starting the Maps MCP server as a subprocess
- Processing the query through Claude with map tools access
- Returning structured results with location information
Testing
Tests for the Google Maps integration are available in tests/ai/test_maps_integration.py.