repositories
loading repo index
repositories
loading repo index
repository
loading code, commits, and activity
public Clawd ADK gateway launch mirror
stars
latest
clone command
git clone gitlawb://did:key:z6Mkq5mY...iFZ5/my-project-publ...git clone gitlawb://did:key:z6Mkq5mY.../my-project-publ...2fa351d6docs: add automaton and perps launch sources16d ago| #1 | --- |
| #2 | name: local-places |
| #3 | description: Search for places (restaurants, cafes, etc.) via Google Places API proxy on localhost. |
| #4 | homepage: https://github.com/Hyaxia/local_places |
| #5 | metadata: {"clawdbot":{"emoji":"📍","requires":{"bins":["uv"],"env":["GOOGLE_PLACES_API_KEY"]},"primaryEnv":"GOOGLE_PLACES_API_KEY"}} |
| #6 | --- |
| #7 | |
| #8 | # 📍 Local Places |
| #9 | |
| #10 | *Find places, Go fast* |
| #11 | |
| #12 | Search for nearby places using a local Google Places API proxy. Two-step flow: resolve location first, then search. |
| #13 | |
| #14 | ## Setup |
| #15 | |
| #16 | ```bash |
| #17 | cd {baseDir} |
| #18 | echo "GOOGLE_PLACES_API_KEY=your-key" > .env |
| #19 | uv venv && uv pip install -e ".[dev]" |
| #20 | uv run --env-file .env uvicorn local_places.main:app --host 127.0.0.1 --port 8000 |
| #21 | ``` |
| #22 | |
| #23 | Requires `GOOGLE_PLACES_API_KEY` in `.env` or environment. |
| #24 | |
| #25 | ## Quick Start |
| #26 | |
| #27 | 1. **Check server:** `curl http://127.0.0.1:8000/ping` |
| #28 | |
| #29 | 2. **Resolve location:** |
| #30 | ```bash |
| #31 | curl -X POST http://127.0.0.1:8000/locations/resolve \ |
| #32 | -H "Content-Type: application/json" \ |
| #33 | -d '{"location_text": "Soho, London", "limit": 5}' |
| #34 | ``` |
| #35 | |
| #36 | 3. **Search places:** |
| #37 | ```bash |
| #38 | curl -X POST http://127.0.0.1:8000/places/search \ |
| #39 | -H "Content-Type: application/json" \ |
| #40 | -d '{ |
| #41 | "query": "coffee shop", |
| #42 | "location_bias": {"lat": 51.5137, "lng": -0.1366, "radius_m": 1000}, |
| #43 | "filters": {"open_now": true, "min_rating": 4.0}, |
| #44 | "limit": 10 |
| #45 | }' |
| #46 | ``` |
| #47 | |
| #48 | 4. **Get details:** |
| #49 | ```bash |
| #50 | curl http://127.0.0.1:8000/places/{place_id} |
| #51 | ``` |
| #52 | |
| #53 | ## Conversation Flow |
| #54 | |
| #55 | 1. If user says "near me" or gives vague location → resolve it first |
| #56 | 2. If multiple results → show numbered list, ask user to pick |
| #57 | 3. Ask for preferences: type, open now, rating, price level |
| #58 | 4. Search with `location_bias` from chosen location |
| #59 | 5. Present results with name, rating, address, open status |
| #60 | 6. Offer to fetch details or refine search |
| #61 | |
| #62 | ## Filter Constraints |
| #63 | |
| #64 | - `filters.types`: exactly ONE type (e.g., "restaurant", "cafe", "gym") |
| #65 | - `filters.price_levels`: integers 0-4 (0=free, 4=very expensive) |
| #66 | - `filters.min_rating`: 0-5 in 0.5 increments |
| #67 | - `filters.open_now`: boolean |
| #68 | - `limit`: 1-20 for search, 1-10 for resolve |
| #69 | - `location_bias.radius_m`: must be > 0 |
| #70 | |
| #71 | ## Response Format |
| #72 | |
| #73 | ```json |
| #74 | { |
| #75 | "results": [ |
| #76 | { |
| #77 | "place_id": "ChIJ...", |
| #78 | "name": "Coffee Shop", |
| #79 | "address": "123 Main St", |
| #80 | "location": {"lat": 51.5, "lng": -0.1}, |
| #81 | "rating": 4.6, |
| #82 | "price_level": 2, |
| #83 | "types": ["cafe", "food"], |
| #84 | "open_now": true |
| #85 | } |
| #86 | ], |
| #87 | "next_page_token": "..." |
| #88 | } |
| #89 | ``` |
| #90 | |
| #91 | Use `next_page_token` as `page_token` in next request for more results. |
| #92 |