Space Window ability#272
Open
hassan1731996 wants to merge 11 commits into
Open
Conversation
Voice-native sky-watching ability: proactive ISS pass alerts, aurora activity monitoring, and rocket launch countdowns — all location-aware. main.py (foreground skill): - Six intents: TONIGHT, ISS, AURORA, LAUNCHES, SETUP, ALERTS - LLM intent router with cheap pre-filter for SETUP - 80+ city map for instant location resolution, LLM fallback - ISS passes via N2YO API (free key, full elevation + compass data) - Aurora Kp index via NOAA Space Weather API (no key required) - Upcoming launches via Launch Library 2 (no key required) - Timezone-aware time formatting via stdlib zoneinfo - Aurora threshold auto-calculated from user latitude (both hemispheres) - Pass quality rating: great (>=60deg), good (>=40deg), fair (>=30deg) background.py (daemon): - 30-minute poll interval; 40-minute ISS alert window prevents missed passes - ISS alert ~10 minutes before pass: rise time, direction, peak elevation - Aurora alert when Kp crosses user latitude threshold, once per day cap - Launch alerts at 24h and 1h before confirmed launches - Daily morning brief at 9am local time - All times in user's local timezone via stored tz string Zero required API keys for aurora and launch features; N2YO free key needed only for ISS pass tracking
Contributor
🔀 Branch Merge CheckPR direction: ✅ Passed — |
Contributor
✅ Community PR Path Check — PassedAll changed files are inside the |
Contributor
✅ Ability Validation Passed |
Contributor
🔍 Lint Results✅
|
- Remove empty f-string in background.py (F541) - Rename ambiguous variable 'l' to 'launch' in two places in main.py (E741) - Reset CONTRIBUTORS.md to upstream/dev
Root cause: _handle_tonight, _handle_iss, and _handle_aurora all spoke a prompt asking the user where they are, then immediately returned and called resume_normal_flow(). The user's answer landed in the generic AI instead of SpaceWindow, so location was never saved and every follow-up trigger hit the same dead end. Fix: add _ensure_location() helper that asks for the city inline, resolves and saves it, then returns True so the original handler continues. All three content handlers now call _ensure_location() instead of early-exiting. First run is now a single natural flow: say "space window" → asked for city → say city → ability proceeds.
7b80644 to
bc87837
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.
What is Space Window?
A sky-watching ability that tells you exactly what's happening above your location tonight — ISS passes, aurora activity, and rocket launches — and alerts you before anything good happens so you never miss it.
Say your city once. After that it handles everything: ISS alerts 10 minutes before a visible pass, aurora alerts when the Kp index spikes high enough for your latitude, and launch countdowns 24 hours and 1 hour before liftoff.
Key Features
Proactive Alerts (background daemon)
Interactive Queries
Smart Details
zoneinfoAPIs Used
Files
community/space-window/main.py— foreground skill (6 intents, LLM router, all handlers)community/space-window/background.py— daemon (ISS/aurora/launch monitoring, morning brief)community/space-window/README.md— trigger phrases, setup, full example conversation