Add MTA Next Train community ability#227
Open
chadnewbry wants to merge 7 commits intoopenhome-dev:devfrom
Open
Add MTA Next Train community ability#227chadnewbry wants to merge 7 commits intoopenhome-dev:devfrom
chadnewbry wants to merge 7 commits intoopenhome-dev:devfrom
Conversation
Contributor
✅ Community PR Path Check — PassedAll changed files are inside the |
Contributor
🔀 Branch Merge CheckPR direction: ✅ Passed — |
Contributor
✅ Ability Validation Passed |
Contributor
🔍 Lint Results🔧 Auto-formattedSome files were automatically cleaned and formatted with
✅
|
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 does this Ability do?
🚇 Adds
MTA Next Train, a voice-first NYC subway arrivals ability for OpenHome. Users can save one default station for the fastest demo path, then ask things like "when's my next train?" or get more specific with line and station filters.Suggested Trigger Words
next trainnext subwaywhen's my next trainsubway arrivalsmtamta next trainType
External APIs
SubwayInfo.nycfor station search + live arrivals. No API key required.Testing
Local Verification
🚉 Fixture tests
python3 -m unittest discover -s community/mta-next-train/tests -v🚉 Ability validation
python3 validate_ability.py community/mta-next-train🚉 Local harness
python3 community/mta-next-train/test_harness.py --phrase "when is the next northbound 6 train at astor place"🚉 Live no-key endpoint check
python3 community/mta-next-train/test_harness.py --live --phrase "next 6 train at astor place"Example live output when tested locally:
Checklist
community/mta-next-train/main.pyfollows SDK pattern (extendsMatchingCapability, hasregister_capability+call)README.mdincluded with description, suggested triggers, and setupresume_normal_flow()called on every exit pathprint()in the ability runtime code — usingeditor_logging_handlerredis,user_config)asyncio.sleep()orasyncio.create_task()— usingsession_tasksAnything else?
🚆 Review route map:
main.pykeeps the OpenHome voice flow thinmta_next_train_core.pyholds the query parsing, station matching, and SubwayInfo clienttest_harness.pygives a quick way to demo both fixture mode and live mode🛤️ Fun demo path for review:
set my default station to Astor Placewhen's my next train?If this lands, it feels like a very clean subway-on-speakers demo: fast, specific, and zero setup friction for the user.